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

Cosmetics.

This commit is contained in:
Sergey Prigogin 2011-05-25 22:04:52 +00:00
parent f5fb221fa2
commit 165d5a38af

View file

@ -6,10 +6,10 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* QNX Software Systems - Initial API and implementation
* Ken Ryall (Nokia) - https://bugs.eclipse.org/bugs/show_bug.cgi?id=118894
* IBM Corporation
* Ericsson
* QNX Software Systems - Initial API and implementation
* Ken Ryall (Nokia) - https://bugs.eclipse.org/bugs/show_bug.cgi?id=118894
* IBM Corporation
* Ericsson
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
@ -54,8 +54,8 @@ import org.eclipse.swt.widgets.Text;
public class CDebuggerTab extends CLaunchConfigurationTab {
/**
* Tab identifier used for ordering of tabs added using the
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
* Tab identifier used for ordering of tabs added using
* the <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
* extension point.
*
* @since 2.0
@ -218,7 +218,8 @@ public class CDebuggerTab extends CLaunchConfigurationTab {
config.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_ID, getDebuggerId());
ICDebuggerPage dynamicTab = getDynamicTab();
if (dynamicTab == null) {
config.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_SPECIFIC_ATTRS_MAP, (Map<?,?>)null);
config.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_SPECIFIC_ATTRS_MAP,
(Map<?, ?>) null);
} else {
dynamicTab.performApply(config);
}
@ -359,10 +360,9 @@ public class CDebuggerTab extends CLaunchConfigurationTab {
ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT));
fStopInMainSymbol.setEnabled(fStopInMain.getSelection());
} else if (fAttachMode) {
// In attach mode, figure out if we are doing a remote connect based on the currently
// chosen debugger
if (getDebuggerId().equals(REMOTE_DEBUGGER_ID)) fRemoteMode = true;
else fRemoteMode = false;
// In attach mode, figure out if we are doing a remote connect based on
// the currently chosen debugger.
fRemoteMode = getDebuggerId().equals(REMOTE_DEBUGGER_ID);
}
} catch (CoreException e) {
}
@ -427,11 +427,11 @@ public class CDebuggerTab extends CLaunchConfigurationTab {
}
protected void setDynamicTab(ICDebuggerPage tab) {
if ( fDynamicTab instanceof ICDebuggerPageExtension )
((ICDebuggerPageExtension)fDynamicTab).removeContentChangeListener( fContentListener );
if (fDynamicTab instanceof ICDebuggerPageExtension)
((ICDebuggerPageExtension) fDynamicTab).removeContentChangeListener(fContentListener);
fDynamicTab = tab;
if ( fDynamicTab instanceof ICDebuggerPageExtension )
((ICDebuggerPageExtension)fDynamicTab).addContentChangeListener( fContentListener );
if (fDynamicTab instanceof ICDebuggerPageExtension)
((ICDebuggerPageExtension) fDynamicTab).addContentChangeListener(fContentListener);
}
protected Composite getDynamicTabHolder() {
@ -468,7 +468,7 @@ public class CDebuggerTab extends CLaunchConfigurationTab {
@Override
public String getErrorMessage() {
ICDebuggerPage tab = getDynamicTab();
if ( (super.getErrorMessage() != null) || (tab == null)) {
if (super.getErrorMessage() != null || tab == null) {
return super.getErrorMessage();
}
return tab.getErrorMessage();
@ -483,25 +483,25 @@ public class CDebuggerTab extends CLaunchConfigurationTab {
// Always set the newly created area with defaults
ILaunchConfigurationWorkingCopy wc = getLaunchConfigurationWorkingCopy();
if (getDynamicTab() == null) {
// Remove any debug specific args from the config
// Remove any debug-specific arguments from the configuration.
if (wc == null) {
if (getLaunchConfiguration().isWorkingCopy()) {
wc = (ILaunchConfigurationWorkingCopy)getLaunchConfiguration();
wc = (ILaunchConfigurationWorkingCopy) getLaunchConfiguration();
}
}
if (wc != null) {
wc.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_SPECIFIC_ATTRS_MAP, (Map<?,?>)null);
wc.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_SPECIFIC_ATTRS_MAP,
(Map<?, ?>) null);
}
} else {
if (wc == null) {
try {
if (getLaunchConfiguration().isWorkingCopy()) {
setLaunchConfigurationWorkingCopy((ILaunchConfigurationWorkingCopy)getLaunchConfiguration());
setLaunchConfigurationWorkingCopy((ILaunchConfigurationWorkingCopy) getLaunchConfiguration());
} else {
setLaunchConfigurationWorkingCopy(getLaunchConfiguration().getWorkingCopy());
}
wc = getLaunchConfigurationWorkingCopy();
} catch (CoreException e) {
return;
}