mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 14:42:11 +02:00
Bug 396466 - [breakpoints] warnings in log related to toggle breakpoint actions
This commit is contained in:
parent
c2605537bc
commit
7ef969fe79
12 changed files with 70 additions and 25 deletions
|
@ -38,10 +38,10 @@ ShowDebuggerConsoleAction.label=Show Debugger Console
|
||||||
ShowDebuggerConsoleAction.tooltip=Show Debugger Console On Target Selection
|
ShowDebuggerConsoleAction.tooltip=Show Debugger Console On Target Selection
|
||||||
|
|
||||||
AddBreakpoint.label=Toggle Brea&kpoint
|
AddBreakpoint.label=Toggle Brea&kpoint
|
||||||
AddBreakpointInteractive.label=&Add Breakpoint...\tCtrl+Double Click
|
AddBreakpointInteractive.label=&Add Breakpoint...
|
||||||
EnableBreakpoint.label=&Toggle Breakpoint Enabled\tShift+Double Click
|
EnableBreakpoint.label=&Toggle Breakpoint Enabled
|
||||||
BreakpointProperties.label=Breakpoint P&roperties...
|
BreakpointProperties.label=Breakpoint P&roperties...
|
||||||
RulerBreakpointProperties.label=Breakpoint P&roperties...\tCtrl+Double Click
|
RulerBreakpointProperties.label=Breakpoint P&roperties...
|
||||||
BreakpointPropertiesCommand.name=C/C++ Breakpoint Properties
|
BreakpointPropertiesCommand.name=C/C++ Breakpoint Properties
|
||||||
BreakpointPropertiesCommand.description=View and edit properties for a given C/C++ breakpoint
|
BreakpointPropertiesCommand.description=View and edit properties for a given C/C++ breakpoint
|
||||||
ManageFunctionBreakpointAction.label=Toggle Breakpoint
|
ManageFunctionBreakpointAction.label=Toggle Breakpoint
|
||||||
|
|
|
@ -39,6 +39,7 @@ import org.eclipse.debug.core.model.IVariable;
|
||||||
import org.eclipse.debug.ui.DebugUITools;
|
import org.eclipse.debug.ui.DebugUITools;
|
||||||
import org.eclipse.debug.ui.contexts.IDebugContextListener;
|
import org.eclipse.debug.ui.contexts.IDebugContextListener;
|
||||||
import org.eclipse.debug.ui.contexts.IDebugContextProvider;
|
import org.eclipse.debug.ui.contexts.IDebugContextProvider;
|
||||||
|
import org.eclipse.jface.bindings.keys.KeyStroke;
|
||||||
import org.eclipse.jface.dialogs.MessageDialog;
|
import org.eclipse.jface.dialogs.MessageDialog;
|
||||||
import org.eclipse.jface.text.BadLocationException;
|
import org.eclipse.jface.text.BadLocationException;
|
||||||
import org.eclipse.jface.text.IDocument;
|
import org.eclipse.jface.text.IDocument;
|
||||||
|
@ -338,4 +339,20 @@ public class CDebugUIUtils {
|
||||||
propertiesAction.run();
|
propertiesAction.run();
|
||||||
propertiesAction.dispose();
|
propertiesAction.dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Formats the given key stroke or click name and the modifier keys
|
||||||
|
* to a key binding string that can be used in action texts.
|
||||||
|
*
|
||||||
|
* @param modifierKeys the modifier keys
|
||||||
|
* @param keyOrClick a key stroke or click, e.g. "Double Click"
|
||||||
|
* @return the formatted keyboard shortcut string, e.g. "Shift+Double Click"
|
||||||
|
*
|
||||||
|
* @since 8.1
|
||||||
|
*/
|
||||||
|
public static final String formatKeyBindingString(int modifierKeys, String keyOrClick) {
|
||||||
|
// this should actually all be delegated to KeyStroke class
|
||||||
|
return KeyStroke.getInstance(modifierKeys, KeyStroke.NO_KEY).format() + keyOrClick;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,14 +37,14 @@ ToggleBreakpointAdapter.Missing_document_2=Missing document
|
||||||
ToggleBreakpointAdapter.Missing_resource_2=Missing resource
|
ToggleBreakpointAdapter.Missing_resource_2=Missing resource
|
||||||
ToggleBreakpointAdapter.Invalid_expression_1=Invalid expression:
|
ToggleBreakpointAdapter.Invalid_expression_1=Invalid expression:
|
||||||
RunToLineAdapter.Operation_is_not_supported_1=Operation is not supported.
|
RunToLineAdapter.Operation_is_not_supported_1=Operation is not supported.
|
||||||
EnableDisableBreakpointRulerAction.Enable_Breakpoint_1=&Enable Breakpoint\tShift+Double Click
|
EnableDisableBreakpointRulerAction.Enable_Breakpoint_1=&Enable Breakpoint
|
||||||
EnableDisableBreakpointRulerAction.Enabling_disabling_breakpoints_1=Enabling/disabling breakpoints
|
EnableDisableBreakpointRulerAction.Enabling_disabling_breakpoints_1=Enabling/disabling breakpoints
|
||||||
EnableDisableBreakpointRulerAction.Exceptions_occurred_enabling_or_disabling_breakpoint_1=Exceptions occurred enabling or disabling the breakpoint
|
EnableDisableBreakpointRulerAction.Exceptions_occurred_enabling_or_disabling_breakpoint_1=Exceptions occurred enabling or disabling the breakpoint
|
||||||
EnableDisableBreakpointRulerAction.Disable_Breakpoint_1=&Disable Breakpoint\tShift+Double Click
|
EnableDisableBreakpointRulerAction.Disable_Breakpoint_1=&Disable Breakpoint
|
||||||
ToggleWatchpointActionDelegate.Operation_failed_1=Operation failed.
|
ToggleWatchpointActionDelegate.Operation_failed_1=Operation failed.
|
||||||
ToggleBreakpointRulerAction.Error_1=Error
|
ToggleBreakpointRulerAction.Error_1=Error
|
||||||
ToggleBreakpointRulerAction.Operation_failed_1=Operation failed
|
ToggleBreakpointRulerAction.Operation_failed_1=Operation failed
|
||||||
CBreakpointPropertiesRulerAction.Breakpoint_Properties=Breakpoint &Properties...\tCtrl+Double Click
|
CBreakpointPropertiesRulerAction.Breakpoint_Properties=Breakpoint &Properties...
|
||||||
CBreakpointPropertiesRulerAction.Error=Unable to edit breakpoint properties.
|
CBreakpointPropertiesRulerAction.Error=Unable to edit breakpoint properties.
|
||||||
ResumeAtLineActionDelegate.Error_1=Error
|
ResumeAtLineActionDelegate.Error_1=Error
|
||||||
ResumeAtLineActionDelegate.1=Error
|
ResumeAtLineActionDelegate.1=Error
|
||||||
|
@ -129,7 +129,8 @@ RetargetAction.0=Error
|
||||||
RetargetAction.1=Operation failed
|
RetargetAction.1=Operation failed
|
||||||
RetargetMoveToLineAction.0=The operation is unavailable on the current selection. Please place the cursor on valid line to run to.
|
RetargetMoveToLineAction.0=The operation is unavailable on the current selection. Please place the cursor on valid line to run to.
|
||||||
RetargetResumeAtLineAction.0=The operation is unavailable on the current selection. Please place the cursor on valid line to run to.
|
RetargetResumeAtLineAction.0=The operation is unavailable on the current selection. Please place the cursor on valid line to run to.
|
||||||
CAddBreakpointInteractiveRulerAction_label=&Add Breakpoint...\tCtrl+Double Click
|
CAddBreakpointInteractiveRulerAction_label=&Add Breakpoint...
|
||||||
CAddBreakpointInteractiveRulerAction_error_title=Error
|
CAddBreakpointInteractiveRulerAction_error_title=Error
|
||||||
CAddBreakpointInteractiveRulerAction_error_message=Unable to create breakpoint
|
CAddBreakpointInteractiveRulerAction_error_message=Unable to create breakpoint
|
||||||
CRulerToggleBreakpointActionDelegate_label=Toggle Brea&kpoint
|
CRulerToggleBreakpointActionDelegate_label=Toggle Brea&kpoint
|
||||||
|
CRulerToggleBreakpointAction_accelerator=Double Click
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
||||||
|
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
||||||
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
||||||
import org.eclipse.cdt.debug.ui.breakpoints.IToggleBreakpointsTargetCExtension;
|
import org.eclipse.cdt.debug.ui.breakpoints.IToggleBreakpointsTargetCExtension;
|
||||||
|
@ -30,6 +31,7 @@ import org.eclipse.jface.text.TextSelection;
|
||||||
import org.eclipse.jface.text.source.IVerticalRulerInfo;
|
import org.eclipse.jface.text.source.IVerticalRulerInfo;
|
||||||
import org.eclipse.jface.viewers.ISelection;
|
import org.eclipse.jface.viewers.ISelection;
|
||||||
import org.eclipse.jface.viewers.ISelectionProvider;
|
import org.eclipse.jface.viewers.ISelectionProvider;
|
||||||
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.ui.IWorkbenchPart;
|
import org.eclipse.ui.IWorkbenchPart;
|
||||||
import org.eclipse.ui.texteditor.IDocumentProvider;
|
import org.eclipse.ui.texteditor.IDocumentProvider;
|
||||||
import org.eclipse.ui.texteditor.ITextEditor;
|
import org.eclipse.ui.texteditor.ITextEditor;
|
||||||
|
@ -68,7 +70,8 @@ public class CAddBreakpointInteractiveRulerAction extends Action implements IUpd
|
||||||
* @param rulerInfo specifies location the user has double-clicked
|
* @param rulerInfo specifies location the user has double-clicked
|
||||||
*/
|
*/
|
||||||
public CAddBreakpointInteractiveRulerAction(IWorkbenchPart part, IDocument document, IVerticalRulerInfo rulerInfo) {
|
public CAddBreakpointInteractiveRulerAction(IWorkbenchPart part, IDocument document, IVerticalRulerInfo rulerInfo) {
|
||||||
super(ActionMessages.getString("CAddBreakpointInteractiveRulerAction_label")); //$NON-NLS-1$
|
super(ActionMessages.getString("CAddBreakpointInteractiveRulerAction_label") + "\t" + //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD1, ActionMessages.getString("CRulerToggleBreakpointAction_accelerator")) ); //$NON-NLS-1$
|
||||||
fPart = part;
|
fPart = part;
|
||||||
fDocument = document;
|
fDocument = document;
|
||||||
fRulerInfo = rulerInfo;
|
fRulerInfo = rulerInfo;
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
||||||
|
|
||||||
import org.eclipse.cdt.debug.core.model.ICBreakpoint;
|
import org.eclipse.cdt.debug.core.model.ICBreakpoint;
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.internal.ui.ICDebugHelpContextIds;
|
import org.eclipse.cdt.debug.internal.ui.ICDebugHelpContextIds;
|
||||||
import org.eclipse.cdt.debug.internal.ui.IInternalCDebugUIConstants;
|
import org.eclipse.cdt.debug.internal.ui.IInternalCDebugUIConstants;
|
||||||
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
||||||
|
@ -25,6 +26,7 @@ import org.eclipse.jface.viewers.ISelection;
|
||||||
import org.eclipse.jface.viewers.ISelectionChangedListener;
|
import org.eclipse.jface.viewers.ISelectionChangedListener;
|
||||||
import org.eclipse.jface.viewers.ISelectionProvider;
|
import org.eclipse.jface.viewers.ISelectionProvider;
|
||||||
import org.eclipse.jface.viewers.StructuredSelection;
|
import org.eclipse.jface.viewers.StructuredSelection;
|
||||||
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.ui.IWorkbenchPart;
|
import org.eclipse.ui.IWorkbenchPart;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -40,7 +42,8 @@ public class CBreakpointPropertiesRulerAction extends AbstractBreakpointRulerAct
|
||||||
*/
|
*/
|
||||||
public CBreakpointPropertiesRulerAction( IWorkbenchPart part, IVerticalRulerInfo info ) {
|
public CBreakpointPropertiesRulerAction( IWorkbenchPart part, IVerticalRulerInfo info ) {
|
||||||
super( part, info );
|
super( part, info );
|
||||||
setText( ActionMessages.getString( "CBreakpointPropertiesRulerAction.Breakpoint_Properties" ) ); //$NON-NLS-1$
|
setText( ActionMessages.getString( "CBreakpointPropertiesRulerAction.Breakpoint_Properties" ) + "\t" + //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD1, ActionMessages.getString("CRulerToggleBreakpointAction_accelerator")) ); //$NON-NLS-1$
|
||||||
part.getSite().getWorkbenchWindow().getWorkbench().getHelpSystem().setHelp( this, ICDebugHelpContextIds.BREAKPOINT_PROPERTIES_ACTION );
|
part.getSite().getWorkbenchWindow().getWorkbench().getHelpSystem().setHelp( this, ICDebugHelpContextIds.BREAKPOINT_PROPERTIES_ACTION );
|
||||||
setId( IInternalCDebugUIConstants.ACTION_BREAKPOINT_PROPERTIES );
|
setId( IInternalCDebugUIConstants.ACTION_BREAKPOINT_PROPERTIES );
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
package org.eclipse.cdt.debug.internal.ui.actions.breakpoints;
|
||||||
|
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.internal.ui.ICDebugHelpContextIds;
|
import org.eclipse.cdt.debug.internal.ui.ICDebugHelpContextIds;
|
||||||
import org.eclipse.cdt.debug.internal.ui.IInternalCDebugUIConstants;
|
import org.eclipse.cdt.debug.internal.ui.IInternalCDebugUIConstants;
|
||||||
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
||||||
|
@ -19,6 +20,7 @@ import org.eclipse.debug.core.DebugPlugin;
|
||||||
import org.eclipse.debug.core.model.IBreakpoint;
|
import org.eclipse.debug.core.model.IBreakpoint;
|
||||||
import org.eclipse.jface.dialogs.ErrorDialog;
|
import org.eclipse.jface.dialogs.ErrorDialog;
|
||||||
import org.eclipse.jface.text.source.IVerticalRulerInfo;
|
import org.eclipse.jface.text.source.IVerticalRulerInfo;
|
||||||
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.ui.IWorkbenchPart;
|
import org.eclipse.ui.IWorkbenchPart;
|
||||||
|
|
||||||
public class EnableDisableBreakpointRulerAction extends AbstractBreakpointRulerAction {
|
public class EnableDisableBreakpointRulerAction extends AbstractBreakpointRulerAction {
|
||||||
|
@ -30,7 +32,8 @@ public class EnableDisableBreakpointRulerAction extends AbstractBreakpointRulerA
|
||||||
*/
|
*/
|
||||||
public EnableDisableBreakpointRulerAction( IWorkbenchPart part, IVerticalRulerInfo info ) {
|
public EnableDisableBreakpointRulerAction( IWorkbenchPart part, IVerticalRulerInfo info ) {
|
||||||
super( part, info );
|
super( part, info );
|
||||||
setText( ActionMessages.getString( "EnableDisableBreakpointRulerAction.Enable_Breakpoint_1" ) ); //$NON-NLS-1$
|
setText( ActionMessages.getString( "EnableDisableBreakpointRulerAction.Enable_Breakpoint_1" ) + "\t" + //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, ActionMessages.getString("CRulerToggleBreakpointAction_accelerator")) ); //$NON-NLS-1$
|
||||||
part.getSite().getWorkbenchWindow().getWorkbench().getHelpSystem().setHelp( this, ICDebugHelpContextIds.ENABLE_DISABLE_BREAKPOINT_ACTION );
|
part.getSite().getWorkbenchWindow().getWorkbench().getHelpSystem().setHelp( this, ICDebugHelpContextIds.ENABLE_DISABLE_BREAKPOINT_ACTION );
|
||||||
setId( IInternalCDebugUIConstants.ACTION_ENABLE_DISABLE_BREAKPOINT );
|
setId( IInternalCDebugUIConstants.ACTION_ENABLE_DISABLE_BREAKPOINT );
|
||||||
}
|
}
|
||||||
|
@ -61,8 +64,13 @@ public class EnableDisableBreakpointRulerAction extends AbstractBreakpointRulerA
|
||||||
setEnabled( fBreakpoint != null );
|
setEnabled( fBreakpoint != null );
|
||||||
if ( isEnabled() ) {
|
if ( isEnabled() ) {
|
||||||
try {
|
try {
|
||||||
boolean enabled = getBreakpoint().isEnabled();
|
if (getBreakpoint().isEnabled()) {
|
||||||
setText( enabled ? ActionMessages.getString( "EnableDisableBreakpointRulerAction.Disable_Breakpoint_1" ) : ActionMessages.getString( "EnableDisableBreakpointRulerAction.Enable_Breakpoint_1" ) ); //$NON-NLS-1$ //$NON-NLS-2$
|
setText( ActionMessages.getString("EnableDisableBreakpointRulerAction.Disable_Breakpoint_1") + "\t" + //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, ActionMessages.getString("CRulerToggleBreakpointAction_accelerator")) ); //$NON-NLS-1$
|
||||||
|
} else {
|
||||||
|
setText( ActionMessages.getString("EnableDisableBreakpointRulerAction.Enable_Breakpoint_1") + "\t" + //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, ActionMessages.getString("CRulerToggleBreakpointAction_accelerator")) ); //$NON-NLS-1$
|
||||||
|
}
|
||||||
}
|
}
|
||||||
catch( CoreException e ) {
|
catch( CoreException e ) {
|
||||||
DebugPlugin.log( e );
|
DebugPlugin.log( e );
|
||||||
|
|
|
@ -31,9 +31,9 @@ commandContext.name= In Disassembly
|
||||||
commandContext.description= When debugging in assembly mode
|
commandContext.description= When debugging in assembly mode
|
||||||
|
|
||||||
# actions
|
# actions
|
||||||
action.breakpointProperties.label = Breakpoint Properties...\Ctrl+Double Click
|
action.breakpointProperties.label = Breakpoint Properties...
|
||||||
action.toggleBreakpoint.label = Toggle Breakpoint\tDouble Click
|
action.toggleBreakpoint.label = Toggle Breakpoint
|
||||||
action.addBreakpoint.label = Add Breakpoint...\tCtrl+Double Click
|
action.addBreakpoint.label = Add Breakpoint...
|
||||||
|
|
||||||
menu.updatePolicy = Update Policy
|
menu.updatePolicy = Update Policy
|
||||||
menu.threadsUpdatePolicy = Threads Update Policy
|
menu.threadsUpdatePolicy = Threads Update Policy
|
||||||
|
|
|
@ -86,6 +86,8 @@ public final class DisassemblyMessages extends NLS {
|
||||||
public static String Disassembly_action_AddBreakpoint_label;
|
public static String Disassembly_action_AddBreakpoint_label;
|
||||||
public static String Disassembly_action_AddBreakpoint_errorTitle;
|
public static String Disassembly_action_AddBreakpoint_errorTitle;
|
||||||
public static String Disassembly_action_AddBreakpoint_errorMessage;
|
public static String Disassembly_action_AddBreakpoint_errorMessage;
|
||||||
|
public static String Disassembly_action_ToggleBreakpoint_accelerator;
|
||||||
|
|
||||||
|
|
||||||
static {
|
static {
|
||||||
NLS.initializeMessages(DisassemblyMessages.class.getName(), DisassemblyMessages.class);
|
NLS.initializeMessages(DisassemblyMessages.class.getName(), DisassemblyMessages.class);
|
||||||
|
|
|
@ -18,14 +18,15 @@ Disassembly_action_GotoPC_tooltip=Go to Current Program Counter
|
||||||
Disassembly_action_GotoAddress_label=Go to Address...
|
Disassembly_action_GotoAddress_label=Go to Address...
|
||||||
Disassembly_action_Copy_label=&Copy
|
Disassembly_action_Copy_label=&Copy
|
||||||
Disassembly_action_SelectAll_label=Select &All
|
Disassembly_action_SelectAll_label=Select &All
|
||||||
Disassembly_action_BreakpointProperties_label=Breakpoint Properties...\tCtrl+Double Click
|
Disassembly_action_BreakpointProperties_label=Breakpoint Properties...
|
||||||
Disassembly_action_DisableBreakpoint_label=Disable Breakpoint\tShift+Double Click
|
Disassembly_action_ToggleBreakpoint_accelerator=Double Click
|
||||||
Disassembly_action_EnableBreakpoint_label=Enable Breakpoint\tShift+Double Click
|
Disassembly_action_EnableBreakpoint_label=Enable Breakpoint
|
||||||
|
Disassembly_action_DisableBreakpoint_label=Disable Breakpoint
|
||||||
Disassembly_action_RefreshView_label=Re&fresh View
|
Disassembly_action_RefreshView_label=Re&fresh View
|
||||||
Disassembly_action_OpenPreferences_label=&Preferences...
|
Disassembly_action_OpenPreferences_label=&Preferences...
|
||||||
Disassembly_action_Sync_label=Link with Active Debug Context
|
Disassembly_action_Sync_label=Link with Active Debug Context
|
||||||
Disassembly_action_TrackExpression_label=Track Expression
|
Disassembly_action_TrackExpression_label=Track Expression
|
||||||
Disassembly_action_AddBreakpoint_label=Add Breakpoint...\tCtrl+Double Click
|
Disassembly_action_AddBreakpoint_label=Add Breakpoint...
|
||||||
Disassembly_action_AddBreakpoint_errorTitle=Error
|
Disassembly_action_AddBreakpoint_errorTitle=Error
|
||||||
Disassembly_action_AddBreakpoint_errorMessage=Unable to create breakpoint
|
Disassembly_action_AddBreakpoint_errorMessage=Unable to create breakpoint
|
||||||
|
|
||||||
|
|
|
@ -31,6 +31,7 @@ import java.util.Map;
|
||||||
|
|
||||||
import org.eclipse.cdt.core.IAddress;
|
import org.eclipse.cdt.core.IAddress;
|
||||||
import org.eclipse.cdt.core.model.ITranslationUnit;
|
import org.eclipse.cdt.core.model.ITranslationUnit;
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.AbstractDisassemblyBackend;
|
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.AbstractDisassemblyBackend;
|
||||||
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.AddressRangePosition;
|
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.AddressRangePosition;
|
||||||
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.DisassemblyPosition;
|
import org.eclipse.cdt.debug.internal.ui.disassembly.dsf.DisassemblyPosition;
|
||||||
|
@ -414,7 +415,8 @@ public abstract class DisassemblyPart extends WorkbenchPart implements IDisassem
|
||||||
private IBreakpoint fBreakpoint;
|
private IBreakpoint fBreakpoint;
|
||||||
public ActionToggleBreakpointEnablement() {
|
public ActionToggleBreakpointEnablement() {
|
||||||
super(DisassemblyPart.this);
|
super(DisassemblyPart.this);
|
||||||
setText(DisassemblyMessages.Disassembly_action_EnableBreakpoint_label);
|
setText(DisassemblyMessages.Disassembly_action_EnableBreakpoint_label + "\t" + //$NON-NLS-1$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, DisassemblyMessages.Disassembly_action_ToggleBreakpoint_accelerator));
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
@ -436,9 +438,11 @@ public abstract class DisassemblyPart extends WorkbenchPart implements IDisassem
|
||||||
fBreakpoint = bps[0];
|
fBreakpoint = bps[0];
|
||||||
try {
|
try {
|
||||||
if (fBreakpoint.isEnabled()) {
|
if (fBreakpoint.isEnabled()) {
|
||||||
setText(DisassemblyMessages.Disassembly_action_DisableBreakpoint_label);
|
setText(DisassemblyMessages.Disassembly_action_DisableBreakpoint_label + "\t" + //$NON-NLS-1$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, DisassemblyMessages.Disassembly_action_ToggleBreakpoint_accelerator));
|
||||||
} else {
|
} else {
|
||||||
setText(DisassemblyMessages.Disassembly_action_EnableBreakpoint_label);
|
setText(DisassemblyMessages.Disassembly_action_EnableBreakpoint_label + "\t" + //$NON-NLS-1$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD2, DisassemblyMessages.Disassembly_action_ToggleBreakpoint_accelerator));
|
||||||
}
|
}
|
||||||
} catch (CoreException e) {
|
} catch (CoreException e) {
|
||||||
setEnabled(false);
|
setEnabled(false);
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
package org.eclipse.cdt.dsf.debug.internal.ui.disassembly.actions;
|
package org.eclipse.cdt.dsf.debug.internal.ui.disassembly.actions;
|
||||||
|
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
import org.eclipse.cdt.debug.internal.ui.actions.ActionMessages;
|
||||||
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
||||||
import org.eclipse.cdt.debug.ui.breakpoints.IToggleBreakpointsTargetCExtension;
|
import org.eclipse.cdt.debug.ui.breakpoints.IToggleBreakpointsTargetCExtension;
|
||||||
|
@ -31,6 +32,7 @@ import org.eclipse.jface.text.source.IVerticalRulerInfo;
|
||||||
import org.eclipse.jface.viewers.ISelection;
|
import org.eclipse.jface.viewers.ISelection;
|
||||||
import org.eclipse.jface.viewers.ISelectionProvider;
|
import org.eclipse.jface.viewers.ISelectionProvider;
|
||||||
import org.eclipse.jface.viewers.StructuredSelection;
|
import org.eclipse.jface.viewers.StructuredSelection;
|
||||||
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.ui.IWorkbenchPart;
|
import org.eclipse.ui.IWorkbenchPart;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -41,7 +43,8 @@ public class AddBreakpointRulerAction extends AbstractDisassemblyBreakpointRuler
|
||||||
|
|
||||||
protected AddBreakpointRulerAction(IDisassemblyPart disassemblyPart, IVerticalRulerInfo rulerInfo) {
|
protected AddBreakpointRulerAction(IDisassemblyPart disassemblyPart, IVerticalRulerInfo rulerInfo) {
|
||||||
super(disassemblyPart, rulerInfo);
|
super(disassemblyPart, rulerInfo);
|
||||||
setText(DisassemblyMessages.Disassembly_action_AddBreakpoint_label);
|
setText(DisassemblyMessages.Disassembly_action_AddBreakpoint_label + "\t" + //$NON-NLS-1$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD1, DisassemblyMessages.Disassembly_action_ToggleBreakpoint_accelerator));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
package org.eclipse.cdt.dsf.debug.internal.ui.disassembly.actions;
|
package org.eclipse.cdt.dsf.debug.internal.ui.disassembly.actions;
|
||||||
|
|
||||||
import org.eclipse.cdt.debug.core.model.ICBreakpoint;
|
import org.eclipse.cdt.debug.core.model.ICBreakpoint;
|
||||||
|
import org.eclipse.cdt.debug.internal.ui.CDebugUIUtils;
|
||||||
import org.eclipse.cdt.debug.ui.breakpoints.CBreakpointPropertyDialogAction;
|
import org.eclipse.cdt.debug.ui.breakpoints.CBreakpointPropertyDialogAction;
|
||||||
import org.eclipse.cdt.dsf.debug.internal.ui.disassembly.DisassemblyMessages;
|
import org.eclipse.cdt.dsf.debug.internal.ui.disassembly.DisassemblyMessages;
|
||||||
import org.eclipse.cdt.dsf.debug.internal.ui.disassembly.provisional.IDisassemblyPart;
|
import org.eclipse.cdt.dsf.debug.internal.ui.disassembly.provisional.IDisassemblyPart;
|
||||||
|
@ -23,6 +24,7 @@ import org.eclipse.jface.viewers.ISelection;
|
||||||
import org.eclipse.jface.viewers.ISelectionChangedListener;
|
import org.eclipse.jface.viewers.ISelectionChangedListener;
|
||||||
import org.eclipse.jface.viewers.ISelectionProvider;
|
import org.eclipse.jface.viewers.ISelectionProvider;
|
||||||
import org.eclipse.jface.viewers.StructuredSelection;
|
import org.eclipse.jface.viewers.StructuredSelection;
|
||||||
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.ui.IWorkbenchPart;
|
import org.eclipse.ui.IWorkbenchPart;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -35,7 +37,8 @@ public class BreakpointPropertiesRulerAction extends AbstractDisassemblyBreakpoi
|
||||||
|
|
||||||
protected BreakpointPropertiesRulerAction(IDisassemblyPart disassemblyPart, IVerticalRulerInfo rulerInfo) {
|
protected BreakpointPropertiesRulerAction(IDisassemblyPart disassemblyPart, IVerticalRulerInfo rulerInfo) {
|
||||||
super(disassemblyPart, rulerInfo);
|
super(disassemblyPart, rulerInfo);
|
||||||
setText(DisassemblyMessages.Disassembly_action_BreakpointProperties_label);
|
setText(DisassemblyMessages.Disassembly_action_BreakpointProperties_label + "\t" + //$NON-NLS-1$
|
||||||
|
CDebugUIUtils.formatKeyBindingString(SWT.MOD1, DisassemblyMessages.Disassembly_action_ToggleBreakpoint_accelerator));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Add table
Reference in a new issue