From 97c1151f0103fb0f194d3a30317473310e39cc93 Mon Sep 17 00:00:00 2001
From: Marc-Andre Laperle
Date: Sun, 5 Jul 2020 22:54:07 -0400
Subject: [PATCH] Bug 564949 - Remove support for CDT 3.X style projects
(partial)
Remove some Wizard classes that are not referenced anywhere anymore.
This commit is just a first of probably several commits but is already
a start. I already had very large commits in progress in the past but
it became big and hard to push so I'd rather do it step by step this
time and at least have some of it done for the next release.
Also moved some messages to its own message bundle in managedbuilder.ui
because it's the only place they are used now.
Change-Id: Ib4258684c91f205dc4af3b17169609b5ebcff253
Signed-off-by: Marc-Andre Laperle
---
.../META-INF/MANIFEST.MF | 2 +-
.../make/internal/ui/MakeResources.properties | 15 --
.../cdt/make/ui/IMakeHelpContextIds.java | 7 -
.../wizards/ConvertToMakeProjectWizard.java | 123 ----------------
.../ConvertToMakeProjectWizardPage.java | 116 ---------------
.../wizards/MakeProjectWizardOptionPage.java | 139 ------------------
.../ui/wizards/NewMakeCCProjectWizard.java | 67 ---------
.../ui/wizards/NewMakeCProjectWizard.java | 52 -------
.../make/ui/wizards/NewMakeProjectWizard.java | 93 ------------
.../internal/ui/wizards/Messages.java | 33 +++++
.../internal/ui/wizards/messages.properties | 18 +++
.../ui/wizards/ConvertToMakeWizardPage.java | 25 ++--
.../guide/deprecated_API_removals.html | 17 +++
13 files changed, 78 insertions(+), 629 deletions(-)
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizard.java
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizardPage.java
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/MakeProjectWizardOptionPage.java
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCCProjectWizard.java
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCProjectWizard.java
delete mode 100644 build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeProjectWizard.java
create mode 100644 build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/Messages.java
create mode 100644 build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/messages.properties
diff --git a/build/org.eclipse.cdt.make.ui/META-INF/MANIFEST.MF b/build/org.eclipse.cdt.make.ui/META-INF/MANIFEST.MF
index 3a08e8b70b7..0a80acfb022 100644
--- a/build/org.eclipse.cdt.make.ui/META-INF/MANIFEST.MF
+++ b/build/org.eclipse.cdt.make.ui/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.make.ui; singleton:=true
-Bundle-Version: 7.3.400.qualifier
+Bundle-Version: 8.0.0.qualifier
Bundle-Activator: org.eclipse.cdt.make.internal.ui.MakeUIPlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/MakeResources.properties b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/MakeResources.properties
index 0b891312884..f6b7cc42994 100644
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/MakeResources.properties
+++ b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/MakeResources.properties
@@ -15,8 +15,6 @@
# IBM Corporation
###############################################################################
-MakeCWizard.title=C/Make Project
-MakeCWizard.description=Create a New C Project using 'make' to build it
MakeEnvironmentBlock.10=&Remove
MakeEnvironmentBlock.11=New Environment Variable
MakeEnvironmentBlock.12=Overwrite variable?
@@ -26,11 +24,7 @@ MakeEnvironmentBlock.15=Select Environment Variables
MakeEnvironmentBlock.16=Edit Environment Variable
MakeEnvironmentBlock.17=&Append environment to native environment
MakeEnvironmentBlock.18=Re&place native environment with specified environment
-MakeCWizard.task_name=Creating C project with Make builder...
-MakeCCWizard.title=C++/Make Project
-MakeCCWizard.description=Create a New C++ Project using 'make' to build it
-MakeCCWizard.task_name=Creating C++ project with Make builder...
MakeEnvironmentBlock.0=Variable
MakeEnvironmentBlock.1=Value
MakeEnvironmentBlock.2=&Name:
@@ -42,15 +36,6 @@ MakeEnvironmentBlock.7=N&ew...
MakeEnvironmentBlock.8=Se&lect...
MakeEnvironmentBlock.9=E&dit...
-MakeCWizardSettings.title=C/Make Project Settings
-MakeCWizardSettings.description=Define the project and 'make' builder settings
-
-MakeCCWizardSettings.title=C++/Make Project Settings
-MakeCCWizardSettings.description=Define the project and 'make' builder settings
-
-WizardMakeProjectConversion.title=Convert to a C/C++ project
-WizardMakeProjectConversion.description=The wizard adds C/C++ Nature to the selected projects to enable C/C++ Tools Support for them.
-WizardMakeProjectConversion.monitor.convertingToMakeProject=Converting to C/C++ Project...
WizardMakeProjectConversion.projectOptions.title=Project options
WizardMakeProjectConversion.projectOptions.projectType=Specify project type
WizardMakeProjectConversion.projectOptions.projectTypeTable=Project type:
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/IMakeHelpContextIds.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/IMakeHelpContextIds.java
index 10c6557f44a..74f0991f05e 100644
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/IMakeHelpContextIds.java
+++ b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/IMakeHelpContextIds.java
@@ -28,13 +28,6 @@ public interface IMakeHelpContextIds {
public static final String SCANNER_CONFIG_DISCOVERY_OPTIONS = PREFIX + "discovery_preferences"; //$NON-NLS-1$
public static final String MAKE_PROP_DISCOVERY = PREFIX + "std_prop_discovery"; //$NON-NLS-1$
public static final String MAKE_VIEW = PREFIX + "make_targets_view"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_NAME_PAGE = PREFIX + "new_proj_wiz_s_name"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_PROJECTS_TAB = PREFIX + "new_proj_wiz_s_proj"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_MAKEBUILDER_TAB = PREFIX + "new_proj_wiz_s_mbuilder"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_ERRORPARSER_TAB = PREFIX + "new_proj_wiz_s_errorp"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_BINARYPARSER_TAB = PREFIX + "new_proj_wiz_s_binary"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_DISCOVERY_TAB = PREFIX + "new_proj_wiz_s_discovery"; //$NON-NLS-1$
- public static final String MAKE_PROJ_WIZ_INDEXER_TAB = PREFIX + "new_proj_wiz_s_cindexer"; //$NON-NLS-1$
public static final String MAKE_PROP_ERROR_PARSER = PREFIX + "std_prop_error"; //$NON-NLS-1$
public static final String MAKE_PROP_BINARY_PARSER = PREFIX + "std_prop_binary"; //$NON-NLS-1$
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizard.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizard.java
deleted file mode 100644
index 8d35034f16e..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizard.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2010 QNX Software Systems and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * QNX Software Systems - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.cdt.make.ui.wizards;
-
-import org.eclipse.cdt.make.core.MakeCorePlugin;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-import org.eclipse.cdt.ui.wizards.conversion.ConversionWizard;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.jface.wizard.Wizard;
-
-/**
- * This wizard provides a method by which the user can
- * add a C nature to a project that previously had no nature associated with it.
- *
- * This wizard was used for 3.X style projects. It is left here for compatibility
- * reasons only. The wizard is superseded by MBS Project Conversion Wizard,
- * class {@code org.eclipse.cdt.managedbuilder.ui.wizards.ConvertToMakeWizard}.
- *
- * @deprecated as of CDT 4.0.
- *
- * @noextend This class is not intended to be subclassed by clients.
- * @noinstantiate This class is not intended to be instantiated by clients.
- */
-@Deprecated
-public class ConvertToMakeProjectWizard extends ConversionWizard {
-
- private static final String WZ_TITLE = "WizardMakeProjectConversion.title"; //$NON-NLS-1$
- private static final String WZ_DESC = "WizardMakeProjectConversion.description"; //$NON-NLS-1$
- private static final String PREFIX = "WizardMakeConversion"; //$NON-NLS-1$
- private static final String WINDOW_TITLE = "WizardMakeConversion.windowTitle"; //$NON-NLS-1$
-
- /**
- * ConvertToStdMakeConversionWizard Wizard constructor
- */
- public ConvertToMakeProjectWizard() {
- this(getWindowTitleResource(), getWzDescriptionResource());
- }
-
- /**
- * ConvertToStdMakeConversionWizard Wizard constructor
- */
- public ConvertToMakeProjectWizard(String title, String desc) {
- super(title, desc);
- }
-
- /**
- * Method getWzDescriptionResource, allows Wizard description label value
- * to be changed by subclasses
- *
- * @return String
- */
- protected static String getWzDescriptionResource() {
- return MakeUIPlugin.getResourceString(WZ_DESC);
- }
-
- /**
- * Method getWzTitleResource, allows Wizard description label value
- * to be changed by subclasses
- *
- * @return String
- */
- protected static String getWzTitleResource() {
- return MakeUIPlugin.getResourceString(WZ_TITLE);
- }
-
- /**
- * Method getWindowTitleResource, allows Wizard Title label value to be
- * changed by subclasses
- *
- * @return String
- */
- protected static String getWindowTitleResource() {
- return MakeUIPlugin.getResourceString(WINDOW_TITLE);
- }
-
- /**
- * Method getPrefix, allows prefix value to be changed by subclasses
- *
- * @return String
- */
- protected static String getPrefix() {
- return PREFIX;
- }
-
- /**
- * Method addPages adds our Simple to C conversion Wizard page.
- *
- * @see Wizard#addPages
- */
- @Override
- public void addPages() {
- addPage(mainPage = new ConvertToMakeProjectWizardPage(getPrefix()));
- }
-
- @Override
- public String getProjectID() {
- return MakeCorePlugin.MAKE_PROJECT_ID;
- }
-
- @Override
- protected void doRun(IProgressMonitor monitor) throws CoreException {
- monitor.beginTask(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.monitor.convertingToMakeProject"), //$NON-NLS-1$
- 2);
- try {
- super.doRun(new SubProgressMonitor(monitor, 1));
- } finally {
- monitor.done();
- }
- }
-}
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizardPage.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizardPage.java
deleted file mode 100644
index df7effb66f1..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/ConvertToMakeProjectWizardPage.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2010 QNX Software Systems and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * QNX Software Systems - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.cdt.make.ui.wizards;
-
-import org.eclipse.cdt.core.CCorePlugin;
-import org.eclipse.cdt.make.core.MakeProjectNature;
-import org.eclipse.cdt.make.core.scannerconfig.ScannerConfigNature;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-import org.eclipse.cdt.ui.wizards.conversion.ConvertProjectWizardPage;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.wizards.newresource.BasicNewResourceWizard;
-
-/**
- *
- * ConvertToStdMakeProjectWizardPage
- * Standard main page for a wizard that adds a C project Nature to a project with no nature associated with it.
- * This conversion is one way in that the project cannot be converted back (i.e have the nature removed).
- *
- * @author Judy N. Green
- * @since Aug 6, 2002
- *
- * Example useage:
- *
- * mainPage = new ConvertToStdMakeProjectWizardPage("ConvertProjectPage");
- * mainPage.setTitle("Project Conversion");
- * mainPage.setDescription("Add C or C++ a Nature to a project.");
- *
- *
- *
- * @deprecated as of CDT 4.0. This page was used for 3.X style projects.
- * It is left here for compatibility reasons only.
- *
- * @noextend This class is not intended to be subclassed by clients.
- * @noinstantiate This class is not intended to be instantiated by clients.
- */
-@Deprecated
-public class ConvertToMakeProjectWizardPage extends ConvertProjectWizardPage {
-
- private static final String WZ_TITLE = "WizardMakeProjectConversion.title"; //$NON-NLS-1$
- private static final String WZ_DESC = "WizardMakeProjectConversion.description"; //$NON-NLS-1$
-
- /**
- * Constructor for ConvertToStdMakeProjectWizardPage.
- */
- public ConvertToMakeProjectWizardPage(String pageName) {
- super(pageName);
- }
-
- /**
- * Method getWzTitleResource returns the correct Title Label for this class
- * overriding the default in the superclass.
- */
- @Override
- protected String getWzTitleResource() {
- return MakeUIPlugin.getResourceString(WZ_TITLE);
- }
-
- /**
- * Method getWzDescriptionResource returns the correct description
- * Label for this class overriding the default in the superclass.
- */
- @Override
- protected String getWzDescriptionResource() {
- return MakeUIPlugin.getResourceString(WZ_DESC);
- }
-
- /**
- * Method isCandidate returns true for all projects.
- */
- @Override
- public boolean isCandidate(IProject project) {
- return true; // all
- }
-
- @Override
- public void convertProject(IProject project, IProgressMonitor monitor, String projectID) throws CoreException {
- monitor.beginTask(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.monitor.convertingToMakeProject"), //$NON-NLS-1$
- 3);
- try {
- super.convertProject(project, new SubProgressMonitor(monitor, 1), projectID);
- MakeProjectNature.addNature(project, new SubProgressMonitor(monitor, 1));
- ScannerConfigNature.addScannerConfigNature(project);
- ScannerConfigNature.initializeDiscoveryOptions(project);
- CCorePlugin.getDefault().mapCProjectOwner(project, projectID, true);
- } finally {
- monitor.done();
- }
- }
-
- @Override
- public void createControl(Composite parent) {
- super.createControl(parent);
- IStructuredSelection sel = ((BasicNewResourceWizard) getWizard()).getSelection();
- if (sel != null) {
- tableViewer.setCheckedElements(sel.toArray());
- setPageComplete(validatePage());
- }
- }
-
-}
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/MakeProjectWizardOptionPage.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/MakeProjectWizardOptionPage.java
deleted file mode 100644
index 334470d109b..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/MakeProjectWizardOptionPage.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2010 IBM Corporation and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- * QNX Software System
- *******************************************************************************/
-
-package org.eclipse.cdt.make.ui.wizards;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.cdt.make.core.MakeCorePlugin;
-import org.eclipse.cdt.make.internal.ui.MakeProjectOptionBlock;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-import org.eclipse.cdt.make.ui.IMakeHelpContextIds;
-import org.eclipse.cdt.ui.dialogs.ICOptionContainer;
-import org.eclipse.cdt.ui.dialogs.ICOptionPage;
-import org.eclipse.cdt.ui.dialogs.IndexerBlock;
-import org.eclipse.cdt.ui.dialogs.ReferenceBlock;
-import org.eclipse.cdt.ui.dialogs.TabFolderOptionBlock;
-import org.eclipse.cdt.ui.wizards.NewCProjectWizard;
-import org.eclipse.cdt.ui.wizards.NewCProjectWizardOptionPage;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Preferences;
-
-/**
- * Standard main page for a wizard that is creates a project resource.
- *
- * This page may be used by clients as-is; it may be also be subclassed to suit.
- *
- *
- * Example usage:
- *
- * mainPage = new CProjectWizardPage("basicCProjectPage");
- * mainPage.setTitle("Project");
- * mainPage.setDescription("Create a new project resource.");
- *
- *
- *
- * @deprecated as of CDT 4.0. This option page was used for New Project Wizard
- * for 3.X style projects.
- *
- * @noextend This class is not intended to be subclassed by clients.
- * @noinstantiate This class is not intended to be instantiated by clients.
- */
-@Deprecated
-public class MakeProjectWizardOptionPage extends NewCProjectWizardOptionPage {
- MakeWizardOptionBlock makeWizardBlock;
-
- public class MakeWizardOptionBlock extends MakeProjectOptionBlock {
- IndexerBlock indexBlock;
-
- public MakeWizardOptionBlock(ICOptionContainer parent) {
- super(parent);
- }
-
- @Override
- protected void addTabs() {
- addTab(new ReferenceBlock());
- super.addTabs();
- addTab(indexBlock = new IndexerBlock());
- }
-
- public void setupHelpContextIds() {
- List pages = getOptionPages();
-
- Iterator iter = pages.iterator();
- for (int i = 0; i < 6 && iter.hasNext(); i++) {
- ICOptionPage page = iter.next();
-
- String id = null;
- switch (i) {
- case 0:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_PROJECTS_TAB;
- break;
- case 1:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_MAKEBUILDER_TAB;
- break;
- case 2:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_ERRORPARSER_TAB;
- break;
- case 3:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_BINARYPARSER_TAB;
- break;
- case 4:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_DISCOVERY_TAB;
- break;
- case 5:
- id = IMakeHelpContextIds.MAKE_PROJ_WIZ_INDEXER_TAB;
- break;
- }
- MakeUIPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(page.getControl(), id);
- }
- }
- }
-
- public MakeProjectWizardOptionPage(String title, String description) {
- super("MakeProjectSettingsPage"); //$NON-NLS-1$
- setTitle(title);
- setDescription(description);
- }
-
- @Override
- protected TabFolderOptionBlock createOptionBlock() {
- return (makeWizardBlock = new MakeWizardOptionBlock(this));
- }
-
- @Override
- public IProject getProject() {
- return ((NewCProjectWizard) getWizard()).getNewProject();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.cdt.ui.dialogs.ICOptionContainer#getPreference()
- */
- @Override
- public Preferences getPreferences() {
- return MakeCorePlugin.getDefault().getPluginPreferences();
- }
-
- public boolean isIndexerEnabled() {
- // isIndexEnabled() * @deprecated always returns false
- // return makeWizardBlock.indexBlock.isIndexEnabled();
- return false;
- }
-
- public void setupHelpContextIds() {
- makeWizardBlock.setupHelpContextIds();
- }
-}
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCCProjectWizard.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCCProjectWizard.java
deleted file mode 100644
index 514910e3646..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCCProjectWizard.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2010 QNX Software Systems and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * QNX Software Systems - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.cdt.make.ui.wizards;
-
-import org.eclipse.cdt.core.CCorePlugin;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.SubProgressMonitor;
-
-/**
- * This wizard was used for 3.X style projects. It is left here for compatibility
- * reasons only. The wizard is superseded by MBS C++ Project Wizard,
- * class {@link org.eclipse.cdt.ui.wizards.CCProjectWizard}.
- *
- * @deprecated as of CDT 4.0.
- *
- * @noextend This class is not intended to be subclassed by clients.
- * @noinstantiate This class is not intended to be instantiated by clients.
- */
-@Deprecated
-public class NewMakeCCProjectWizard extends NewMakeProjectWizard {
-
- private static final String WZ_TITLE = "MakeCCWizard.title"; //$NON-NLS-1$
- private static final String WZ_DESC = "MakeCCWizard.description"; //$NON-NLS-1$
-
- private static final String WZ_SETTINGS_TITLE = "MakeCCWizard.title"; //$NON-NLS-1$
- private static final String WZ_SETTINGS_DESC = "MakeCCWizard.description"; //$NON-NLS-1$
-
- public NewMakeCCProjectWizard() {
- super(MakeUIPlugin.getResourceString(WZ_TITLE), MakeUIPlugin.getResourceString(WZ_DESC));
- }
-
- @Override
- public void addPages() {
- super.addPages();
- addPage(fOptionPage = new MakeProjectWizardOptionPage(MakeUIPlugin.getResourceString(WZ_SETTINGS_TITLE),
- MakeUIPlugin.getResourceString(WZ_SETTINGS_DESC)));
- }
-
- @Override
- protected void doRun(IProgressMonitor monitor) throws CoreException {
- if (monitor == null) {
- monitor = new NullProgressMonitor();
- }
- monitor.beginTask(MakeUIPlugin.getResourceString("MakeCCWizard.task_name"), 10); //$NON-NLS-1$
- super.doRun(new SubProgressMonitor(monitor, 9));
- // Add C++ Nature.
- if (newProject != null) {
- // Add C++ Nature to the newly created project.
- CCorePlugin.getDefault().convertProjectFromCtoCC(newProject, new SubProgressMonitor(monitor, 1));
- }
- monitor.done();
- }
-}
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCProjectWizard.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCProjectWizard.java
deleted file mode 100644
index fff3b8c8202..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeCProjectWizard.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2010 QNX Software Systems and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * QNX Software Systems - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.cdt.make.ui.wizards;
-
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-
-/**
- * This wizard was used for 3.X style projects. It is left here for compatibility
- * reasons only. The wizard is superseded by MBS C Project Wizard,
- * class {@link org.eclipse.cdt.ui.wizards.CProjectWizard}.
- *
- * @deprecated as of CDT 4.0.
- *
- * @noextend This class is not intended to be subclassed by clients.
- * @noinstantiate This class is not intended to be instantiated by clients.
- */
-@Deprecated
-public class NewMakeCProjectWizard extends NewMakeProjectWizard {
-
- private static final String WZ_TITLE = "MakeCWizard.title"; //$NON-NLS-1$
- private static final String WZ_DESC = "MakeCWizard.description"; //$NON-NLS-1$'
-
- private static final String WZ_SETTINGS_TITLE = "MakeCWizardSettings.title"; //$NON-NLS-1$
- private static final String WZ_SETTINGS_DESC = "MakeCWizardSettings.description"; //$NON-NLS-1$'
-
- public NewMakeCProjectWizard() {
- this(MakeUIPlugin.getResourceString(WZ_TITLE), MakeUIPlugin.getResourceString(WZ_DESC));
- }
-
- public NewMakeCProjectWizard(String title, String desc) {
- super(title, desc);
- }
-
- @Override
- public void addPages() {
- super.addPages();
- addPage(fOptionPage = new MakeProjectWizardOptionPage(MakeUIPlugin.getResourceString(WZ_SETTINGS_TITLE),
- MakeUIPlugin.getResourceString(WZ_SETTINGS_DESC)));
- }
-
-}
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeProjectWizard.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeProjectWizard.java
deleted file mode 100644
index 2d72a9b8db8..00000000000
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/ui/wizards/NewMakeProjectWizard.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2010 QNX Software Systems and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * QNX Software Systems - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.cdt.make.ui.wizards;
-
-import org.eclipse.cdt.make.core.MakeCorePlugin;
-import org.eclipse.cdt.make.core.MakeProjectNature;
-import org.eclipse.cdt.make.core.scannerconfig.ScannerConfigNature;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
-import org.eclipse.cdt.make.ui.IMakeHelpContextIds;
-import org.eclipse.cdt.ui.wizards.NewCProjectWizard;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * This abstract wizard was used for 3.X style projects. It is left here for compatibility
- * reasons only. The wizards are superseded by MBS C++ Project Wizards.
- *
- * @deprecated as of CDT 4.0.
- *
- * @noextend This class is not intended to be subclassed by clients.
- */
-@Deprecated
-public abstract class NewMakeProjectWizard extends NewCProjectWizard {
-
- protected MakeProjectWizardOptionPage fOptionPage;
-
- public NewMakeProjectWizard(String title, String desc) {
- super(title, desc);
- }
-
- @Override
- protected void doRunPrologue(IProgressMonitor monitor) {
- }
-
- @Override
- protected void doRunEpilogue(IProgressMonitor monitor) {
- }
-
- @Override
- protected void doRun(IProgressMonitor monitor) throws CoreException {
- if (monitor == null) {
- monitor = new NullProgressMonitor();
- }
- monitor.beginTask(MakeUIPlugin.getResourceString("MakeCWizard.task_name"), 10); //$NON-NLS-1$
-
- // super.doRun() just creates the project and does not assign a builder to it.
- super.doRun(new SubProgressMonitor(monitor, 5));
-
- MakeProjectNature.addNature(getProjectHandle(), new SubProgressMonitor(monitor, 1));
- ScannerConfigNature.addScannerConfigNature(getProjectHandle());
-
- // Modify the project based on what the user has selected
- if (newProject != null) {
- fOptionPage.performApply(new SubProgressMonitor(monitor, 4));
- monitor.done();
- }
- }
-
- @Override
- public String getProjectID() {
- return MakeCorePlugin.MAKE_PROJECT_ID;
- }
-
- @Override
- public void createPageControls(Composite pageContainer) {
- super.createPageControls(pageContainer);
-
- IWizardPage[] pages = getPages();
-
- if (pages != null && pages.length == 2) {
- MakeUIPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(pages[0].getControl(),
- IMakeHelpContextIds.MAKE_PROJ_WIZ_NAME_PAGE);
-
- MakeProjectWizardOptionPage optionPage = (MakeProjectWizardOptionPage) pages[1];
- optionPage.setupHelpContextIds();
- }
- }
-}
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/Messages.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/Messages.java
new file mode 100644
index 00000000000..b9c0506d206
--- /dev/null
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/Messages.java
@@ -0,0 +1,33 @@
+/*******************************************************************************
+ * Copyright (c) 2020 Marc-Andre Laperle.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *******************************************************************************/
+
+package org.eclipse.cdt.managedbuilder.internal.ui.wizards;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.cdt.managedbuilder.internal.ui.wizards.messages"; //$NON-NLS-1$
+ public static String WizardMakeProjectConversion_title;
+ public static String WizardMakeProjectConversion_description;
+ public static String WizardMakeProjectConversion_monitor_convertingToMakeProject;
+ public static String WizardMakeProjectConversion_projectOptions_title;
+ public static String WizardMakeProjectConversion_projectOptions_projectType;
+ public static String WizardMakeProjectConversion_projectOptions_projectTypeTable;
+ public static String WizardMakeProjectConversion_projectOptions_showSuppressed;
+
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/messages.properties b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/messages.properties
new file mode 100644
index 00000000000..9310ffef0fe
--- /dev/null
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/wizards/messages.properties
@@ -0,0 +1,18 @@
+###############################################################################
+# Copyright (c) 2020 Marc-Andre Laperle and others.
+#
+# This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License 2.0
+# which accompanies this distribution, and is available at
+# https://www.eclipse.org/legal/epl-2.0/
+#
+# SPDX-License-Identifier: EPL-2.0
+###############################################################################
+
+WizardMakeProjectConversion_title=Convert to a C/C++ project
+WizardMakeProjectConversion_description=The wizard adds C/C++ Nature to the selected projects to enable C/C++ Tools Support for them.
+WizardMakeProjectConversion_monitor_convertingToMakeProject=Converting to C/C++ Project...
+WizardMakeProjectConversion_projectOptions_title=Project options
+WizardMakeProjectConversion_projectOptions_projectType=Specify project type
+WizardMakeProjectConversion_projectOptions_projectTypeTable=Project type:
+WizardMakeProjectConversion_projectOptions_showSuppressed=Show project types and toolchains only if they are supported on the platform
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/wizards/ConvertToMakeWizardPage.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/wizards/ConvertToMakeWizardPage.java
index 35f04bdaf6c..a2e266b558d 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/wizards/ConvertToMakeWizardPage.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/wizards/ConvertToMakeWizardPage.java
@@ -20,7 +20,7 @@ import java.util.ArrayList;
import java.util.List;
import org.eclipse.cdt.core.CCProjectNature;
-import org.eclipse.cdt.make.internal.ui.MakeUIPlugin;
+import org.eclipse.cdt.managedbuilder.internal.ui.wizards.Messages;
import org.eclipse.cdt.ui.newui.AbstractPage;
import org.eclipse.cdt.ui.newui.CDTPrefUtil;
import org.eclipse.cdt.ui.newui.PageLayout;
@@ -53,9 +53,6 @@ import org.eclipse.ui.wizards.newresource.BasicNewResourceWizard;
* @noinstantiate This class is not intended to be instantiated by clients.
*/
public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
- private static final String WZ_TITLE = "WizardMakeProjectConversion.title"; //$NON-NLS-1$
- private static final String WZ_DESC = "WizardMakeProjectConversion.description"; //$NON-NLS-1$
-
/**
* @since 5.1
*/
@@ -96,14 +93,13 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
layoutData.heightHint = 200;
optionsGroup.setLayoutData(layoutData);
optionsGroup.setLayout(new GridLayout(1, true));
- optionsGroup.setText(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.projectOptions.title")); //$NON-NLS-1$
+ optionsGroup.setText(Messages.WizardMakeProjectConversion_projectOptions_title);
Composite c = new Composite(optionsGroup, SWT.NONE);
c.setLayoutData(new GridData(GridData.FILL_BOTH));
c.setLayout(new GridLayout(2, true));
specifyProjectTypeButton = new Button(c, SWT.CHECK);
- specifyProjectTypeButton
- .setText(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.projectOptions.projectType")); //$NON-NLS-1$
+ specifyProjectTypeButton.setText(Messages.WizardMakeProjectConversion_projectOptions_projectType);
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
gd.horizontalSpan = 2;
specifyProjectTypeButton.setLayoutData(gd);
@@ -115,8 +111,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
});
left_label = new Label(c, SWT.NONE);
- left_label
- .setText(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.projectOptions.projectTypeTable")); //$NON-NLS-1$
+ left_label.setText(Messages.WizardMakeProjectConversion_projectOptions_projectTypeTable);
left_label.setFont(container.getFont());
left_label.setLayoutData(new GridData(GridData.BEGINNING));
@@ -141,7 +136,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
show_sup = new Button(c, SWT.CHECK);
show_sup.setSelection(true);
- show_sup.setText(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.projectOptions.showSuppressed")); //$NON-NLS-1$
+ show_sup.setText(Messages.WizardMakeProjectConversion_projectOptions_showSuppressed);
gd = new GridData(GridData.FILL_HORIZONTAL);
gd.horizontalSpan = 2;
show_sup.setLayoutData(gd);
@@ -233,7 +228,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
*/
@Override
protected String getWzTitleResource() {
- return MakeUIPlugin.getResourceString(WZ_TITLE);
+ return Messages.WizardMakeProjectConversion_title;
}
/**
@@ -242,7 +237,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
*/
@Override
protected String getWzDescriptionResource() {
- return MakeUIPlugin.getResourceString(WZ_DESC);
+ return Messages.WizardMakeProjectConversion_description;
}
/**
@@ -265,8 +260,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
@Override
public void convertProject(IProject project, String bsId, IProgressMonitor monitor) throws CoreException {
- monitor.beginTask(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.monitor.convertingToMakeProject"), //$NON-NLS-1$
- 3);
+ monitor.beginTask(Messages.WizardMakeProjectConversion_monitor_convertingToMakeProject, 3);
try {
boolean wasCDTProject = AbstractPage.isCDTPrj(project);
super.convertProject(project, bsId, new SubProgressMonitor(monitor, 1));
@@ -280,8 +274,7 @@ public class ConvertToMakeWizardPage extends ConvertProjectWizardPage {
@Override
public void convertProject(IProject project, IProgressMonitor monitor, String projectID) throws CoreException {
- monitor.beginTask(MakeUIPlugin.getResourceString("WizardMakeProjectConversion.monitor.convertingToMakeProject"), //$NON-NLS-1$
- 3);
+ monitor.beginTask(Messages.WizardMakeProjectConversion_monitor_convertingToMakeProject, 3);
try {
boolean wasCDTProject = AbstractPage.isCDTPrj(project);
super.convertProject(project, new SubProgressMonitor(monitor, 1), projectID);
diff --git a/doc/org.eclipse.cdt.doc.isv/guide/deprecated_API_removals.html b/doc/org.eclipse.cdt.doc.isv/guide/deprecated_API_removals.html
index 4317734ce8d..5a16e92effb 100644
--- a/doc/org.eclipse.cdt.doc.isv/guide/deprecated_API_removals.html
+++ b/doc/org.eclipse.cdt.doc.isv/guide/deprecated_API_removals.html
@@ -41,6 +41,7 @@
Remove LRParser, XLC and UPC.
Remove org.eclipse.cdt.utils.Platform.
DSF and DSF-GDB API Changes.
+ Partial removal of CDT 3.X project support.
Planned Removals after June 2022
@@ -198,6 +199,22 @@
+
+
+ CDT 3.X projects have been deprecated since CDT 4.0. Some classes supporting this old version have been removed:
+
+ - org.eclipse.cdt.make.ui.wizards.ConvertToMakeProjectWizard
+ - org.eclipse.cdt.make.ui.wizards.ConvertToMakeProjectWizardPage
+ - org.eclipse.cdt.make.ui.wizards.MakeProjectWizardOptionPage
+ - org.eclipse.cdt.make.ui.wizards.NewMakeCCProjectWizard
+ - org.eclipse.cdt.make.ui.wizards.NewMakeCProjectWizard
+ - org.eclipse.cdt.make.ui.wizards.NewMakeProjectWizard
+
+
+
+ See Bug 564949.
+
+
Future Deletions