mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-07 01:36:01 +02:00
Bug 316987: Show full paths preference under C/C++->Debug is not really necessary
This commit is contained in:
parent
b1aa24fe34
commit
c39daa9ca9
7 changed files with 15 additions and 16 deletions
|
@ -18,7 +18,7 @@ Export-Package: org.eclipse.cdt.debug.core,
|
||||||
org.eclipse.cdt.debug.core.model,
|
org.eclipse.cdt.debug.core.model,
|
||||||
org.eclipse.cdt.debug.core.model.provisional;x-friends:="org.eclipse.cdt.dsf,org.eclipse.cdt.debug.ui.memory.memorybrowser,org.eclipse.cdt.dsf.gdb",
|
org.eclipse.cdt.debug.core.model.provisional;x-friends:="org.eclipse.cdt.dsf,org.eclipse.cdt.debug.ui.memory.memorybrowser,org.eclipse.cdt.dsf.gdb",
|
||||||
org.eclipse.cdt.debug.core.sourcelookup,
|
org.eclipse.cdt.debug.core.sourcelookup,
|
||||||
org.eclipse.cdt.debug.internal.core;x-friends:="org.eclipse.cdt.dsf.gdb.ui",
|
org.eclipse.cdt.debug.internal.core;x-friends:="org.eclipse.cdt.dsf.gdb.ui,org.eclipse.cdt.dsf,org.eclipse.cdt.dsf.ui",
|
||||||
org.eclipse.cdt.debug.internal.core.breakpoints;x-friends:="org.eclipse.cdt.debug.edc,org.eclipse.cdt.dsf.gdb",
|
org.eclipse.cdt.debug.internal.core.breakpoints;x-friends:="org.eclipse.cdt.debug.edc,org.eclipse.cdt.dsf.gdb",
|
||||||
org.eclipse.cdt.debug.internal.core.executables;x-internal:=true,
|
org.eclipse.cdt.debug.internal.core.executables;x-internal:=true,
|
||||||
org.eclipse.cdt.debug.internal.core.model;x-internal:=true,
|
org.eclipse.cdt.debug.internal.core.model;x-internal:=true,
|
||||||
|
|
|
@ -28,4 +28,12 @@ public class ICDebugInternalConstants {
|
||||||
* String preference for the common source containers.
|
* String preference for the common source containers.
|
||||||
*/
|
*/
|
||||||
public static final String PREF_COMMON_SOURCE_CONTAINERS = CDebugCorePlugin.getUniqueIdentifier() + ".cDebug.common_source_containers"; //$NON-NLS-1$
|
public static final String PREF_COMMON_SOURCE_CONTAINERS = CDebugCorePlugin.getUniqueIdentifier() + ".cDebug.common_source_containers"; //$NON-NLS-1$
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Boolean preference indicating the on/off state of the Show Full Paths
|
||||||
|
* toggle action. Actually, as the action appears in multiple views, and the
|
||||||
|
* state is preserved for each view, the full preference key is the view ID
|
||||||
|
* plus this key
|
||||||
|
*/
|
||||||
|
public static final String SHOW_FULL_PATHS_PREF_KEY = "org.eclipse.cdt.debug.ui.cDebug.show_full_paths"; //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
package org.eclipse.cdt.debug.internal.ui.actions;
|
package org.eclipse.cdt.debug.internal.ui.actions;
|
||||||
|
|
||||||
import org.eclipse.cdt.debug.core.CDIDebugModel;
|
import org.eclipse.cdt.debug.core.CDIDebugModel;
|
||||||
|
import org.eclipse.cdt.debug.internal.core.ICDebugInternalConstants;
|
||||||
import org.eclipse.cdt.debug.internal.ui.CDebugModelPresentation;
|
import org.eclipse.cdt.debug.internal.ui.CDebugModelPresentation;
|
||||||
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
||||||
import org.eclipse.debug.core.DebugPlugin;
|
import org.eclipse.debug.core.DebugPlugin;
|
||||||
|
@ -34,13 +35,11 @@ import org.eclipse.swt.custom.BusyIndicator;
|
||||||
*/
|
*/
|
||||||
public class ShowFullPathsAction extends ViewFilterAction {
|
public class ShowFullPathsAction extends ViewFilterAction {
|
||||||
|
|
||||||
public static final String PREF_KEY = "org.eclipse.cdt.debug.ui.cDebug.show_full_paths"; //$NON-NLS-1$
|
|
||||||
|
|
||||||
/* (non-Javadoc)
|
/* (non-Javadoc)
|
||||||
* @see org.eclipse.cdt.debug.internal.ui.actions.ViewFilterAction#getPreferenceKey()
|
* @see org.eclipse.cdt.debug.internal.ui.actions.ViewFilterAction#getPreferenceKey()
|
||||||
*/
|
*/
|
||||||
protected String getPreferenceKey() {
|
protected String getPreferenceKey() {
|
||||||
return PREF_KEY;
|
return ICDebugInternalConstants.SHOW_FULL_PATHS_PREF_KEY;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* (non-Javadoc)
|
/* (non-Javadoc)
|
||||||
|
|
|
@ -175,7 +175,6 @@ public class CDebugPreferencePage extends PreferencePage implements IWorkbenchPr
|
||||||
*/
|
*/
|
||||||
public static void initDefaults( IPreferenceStore store ) {
|
public static void initDefaults( IPreferenceStore store ) {
|
||||||
store.setDefault( ICDebugPreferenceConstants.PREF_SHOW_HEX_VALUES, false );
|
store.setDefault( ICDebugPreferenceConstants.PREF_SHOW_HEX_VALUES, false );
|
||||||
// store.setDefault( ICDebugPreferenceConstants.PREF_SHOW_FULL_PATHS, true );
|
|
||||||
PreferenceConverter.setDefault( store, IInternalCDebugUIConstants.DISASSEMBLY_SOURCE_LINE_COLOR, IInternalCDebugUIConstants.DEFAULT_DISASSEMBLY_SOURCE_LINE_RGB );
|
PreferenceConverter.setDefault( store, IInternalCDebugUIConstants.DISASSEMBLY_SOURCE_LINE_COLOR, IInternalCDebugUIConstants.DEFAULT_DISASSEMBLY_SOURCE_LINE_RGB );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,6 @@ CDebugPreferencePage.1=Hexadecimal
|
||||||
CDebugPreferencePage.2=Decimal
|
CDebugPreferencePage.2=Decimal
|
||||||
CDebugPreferencePage.3=General settings for C/C++ Debugging.
|
CDebugPreferencePage.3=General settings for C/C++ Debugging.
|
||||||
CDebugPreferencePage.4=Opened view default settings
|
CDebugPreferencePage.4=Opened view default settings
|
||||||
CDebugPreferencePage.5=Show full &paths
|
|
||||||
CDebugPreferencePage.8=Default variable format:
|
CDebugPreferencePage.8=Default variable format:
|
||||||
CDebugPreferencePage.9=Default expression format:
|
CDebugPreferencePage.9=Default expression format:
|
||||||
CDebugPreferencePage.10=Default register format:
|
CDebugPreferencePage.10=Default register format:
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
package org.eclipse.cdt.dsf.debug.ui;
|
package org.eclipse.cdt.dsf.debug.ui;
|
||||||
|
|
||||||
import org.eclipse.cdt.debug.internal.ui.actions.ShowFullPathsAction;
|
import org.eclipse.cdt.debug.internal.core.ICDebugInternalConstants;
|
||||||
import org.eclipse.cdt.dsf.internal.ui.DsfUIPlugin;
|
import org.eclipse.cdt.dsf.internal.ui.DsfUIPlugin;
|
||||||
import org.eclipse.debug.ui.IDebugUIConstants;
|
import org.eclipse.debug.ui.IDebugUIConstants;
|
||||||
|
|
||||||
|
@ -94,5 +94,5 @@ public interface IDsfDebugUIConstants {
|
||||||
* The value of this id must match what is being used as a full key in ShowFullPathsAction.run()
|
* The value of this id must match what is being used as a full key in ShowFullPathsAction.run()
|
||||||
*
|
*
|
||||||
* @since 2.1 */
|
* @since 2.1 */
|
||||||
public static final String DEBUG_VIEW_SHOW_FULL_PATH_PROPERTY = IDebugUIConstants.ID_DEBUG_VIEW + "." + ShowFullPathsAction.PREF_KEY; //$NON-NLS-1$
|
public static final String DEBUG_VIEW_SHOW_FULL_PATH_PROPERTY = IDebugUIConstants.ID_DEBUG_VIEW + "." + ICDebugInternalConstants.SHOW_FULL_PATHS_PREF_KEY; //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
package org.eclipse.cdt.dsf.debug.model;
|
package org.eclipse.cdt.dsf.debug.model;
|
||||||
|
|
||||||
|
import org.eclipse.cdt.debug.internal.core.ICDebugInternalConstants;
|
||||||
import org.eclipse.debug.core.DebugPlugin;
|
import org.eclipse.debug.core.DebugPlugin;
|
||||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||||
import org.eclipse.debug.core.Launch;
|
import org.eclipse.debug.core.Launch;
|
||||||
|
@ -24,20 +25,13 @@ import org.eclipse.debug.core.model.ISourceLocator;
|
||||||
*/
|
*/
|
||||||
public class DsfLaunch extends Launch {
|
public class DsfLaunch extends Launch {
|
||||||
|
|
||||||
/*
|
|
||||||
* Used to indicate that this launch supports the "Show Full Path" action in the debug view.
|
|
||||||
* This constant must have the same value as ICDebugPreferenceConstants.PREF_SHOW_FULL_PATHS
|
|
||||||
* We have our own copy to avoid a dependency.
|
|
||||||
*/
|
|
||||||
private static final String PREF_SHOW_FULL_PATHS = "org.eclipse.cdt.debug.ui.cDebug.show_full_paths"; //$NON-NLS-1$
|
|
||||||
|
|
||||||
public DsfLaunch(ILaunchConfiguration launchConfiguration, String mode, ISourceLocator locator) {
|
public DsfLaunch(ILaunchConfiguration launchConfiguration, String mode, ISourceLocator locator) {
|
||||||
super(launchConfiguration, mode, locator);
|
super(launchConfiguration, mode, locator);
|
||||||
|
|
||||||
// Just set this attribute to any value. It's presence indicates that the
|
// Just set this attribute to any value. It's presence indicates that the
|
||||||
// "Show Full Path" action is supported in the debug view.
|
// "Show Full Path" action is supported in the debug view.
|
||||||
// see org.eclipse.cdt.debug.internal.ui.actions.ShowFullPathsAction
|
// see org.eclipse.cdt.debug.internal.ui.actions.ShowFullPathsAction
|
||||||
setAttribute(PREF_SHOW_FULL_PATHS, ""); //$NON-NLS-1$
|
setAttribute(ICDebugInternalConstants.SHOW_FULL_PATHS_PREF_KEY, ""); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Add table
Reference in a new issue