1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-07 17:56:01 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2014-01-22 11:46:21 -08:00
parent 18893e0ffc
commit ad526b4fb0
2 changed files with 10 additions and 23 deletions

View file

@ -10,16 +10,17 @@
*******************************************************************************/ *******************************************************************************/
package org.eclipse.cdt.internal.ui.wizards; package org.eclipse.cdt.internal.ui.wizards;
import org.eclipse.cdt.internal.ui.CPluginImages;
import org.eclipse.cdt.internal.ui.wizards.classwizard.NewClassWizardMessages;
import org.eclipse.cdt.ui.CUIPlugin;
import org.eclipse.cdt.ui.wizards.NewClassCreationWizardPage;
import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFile;
import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IProgressMonitor;
public class NewClassCreationWizard extends NewElementWizard { import org.eclipse.cdt.ui.CUIPlugin;
import org.eclipse.cdt.ui.wizards.NewClassCreationWizardPage;
import org.eclipse.cdt.internal.ui.CPluginImages;
import org.eclipse.cdt.internal.ui.wizards.classwizard.NewClassWizardMessages;
public class NewClassCreationWizard extends NewElementWizard {
private NewClassCreationWizardPage fPage; private NewClassCreationWizardPage fPage;
public NewClassCreationWizard() { public NewClassCreationWizard() {
@ -40,31 +41,16 @@ public class NewClassCreationWizard extends NewElementWizard {
fPage.init(getSelection()); fPage.init(getSelection());
} }
/*
* (non-Javadoc)
*
* @see org.eclipse.cdt.internal.ui.wizards.NewElementWizard#canRunForked()
*/
@Override @Override
protected boolean canRunForked() { protected boolean canRunForked() {
return !fPage.isNamespaceSelected(); return !fPage.isNamespaceSelected();
} }
/*
* (non-Javadoc)
*
* @see org.eclipse.cdt.internal.ui.wizards.NewElementWizard#finishPage(org.eclipse.core.runtime.IProgressMonitor)
*/
@Override @Override
protected void finishPage(IProgressMonitor monitor) throws InterruptedException, CoreException { protected void finishPage(IProgressMonitor monitor) throws InterruptedException, CoreException {
fPage.createClass(monitor); // use the full progress monitor fPage.createClass(monitor); // use the full progress monitor
} }
/*
* (non-Javadoc)
*
* @see org.eclipse.jface.wizard.IWizard#performFinish()
*/
@Override @Override
public boolean performFinish() { public boolean performFinish() {
boolean finished = super.performFinish(); boolean finished = super.performFinish();

View file

@ -691,12 +691,13 @@ public class NewClassCodeGenerator {
if (i > 0) if (i > 0)
text.append(", "); //$NON-NLS-1$ text.append(", "); //$NON-NLS-1$
if (baseClass.getAccess() == ASTAccessVisibility.PRIVATE) if (baseClass.getAccess() == ASTAccessVisibility.PRIVATE) {
text.append("private"); //$NON-NLS-1$ text.append("private"); //$NON-NLS-1$
else if (baseClass.getAccess() == ASTAccessVisibility.PROTECTED) } else if (baseClass.getAccess() == ASTAccessVisibility.PROTECTED) {
text.append("private"); //$NON-NLS-1$ text.append("private"); //$NON-NLS-1$
else } else {
text.append("public"); //$NON-NLS-1$ text.append("public"); //$NON-NLS-1$
}
text.append(' '); text.append(' ');
if (baseClass.isVirtual()) if (baseClass.isVirtual())