Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.debug.ui/.classpath16
-rw-r--r--org.eclipse.debug.ui/.project4
-rw-r--r--org.eclipse.debug.ui/plugin.xml131
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/FollowHyperlinkAction.java3
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/OpenBreakpointMarkerAction.java5
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleDocumentProvider.java20
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsolePage.java37
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java5
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java29
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugView.java12
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/console/FileLink.java3
11 files changed, 141 insertions, 124 deletions
diff --git a/org.eclipse.debug.ui/.classpath b/org.eclipse.debug.ui/.classpath
index f55c0d5bf..88983197a 100644
--- a/org.eclipse.debug.ui/.classpath
+++ b/org.eclipse.debug.ui/.classpath
@@ -1,14 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="src" path="ui/"/>
+ <classpathentry kind="src" path="ui"/>
<classpathentry kind="src" path="/org.eclipse.core.resources"/>
+ <classpathentry kind="src" path="/org.eclipse.core.variables"/>
<classpathentry kind="src" path="/org.eclipse.ui"/>
+ <classpathentry kind="src" path="/org.eclipse.ui.console"/>
+ <classpathentry kind="src" path="/org.eclipse.help"/>
<classpathentry kind="src" path="/org.eclipse.debug.core"/>
- <classpathentry kind="src" path="/org.eclipse.core.runtime"/>
+ <classpathentry kind="src" path="/org.eclipse.jface.text"/>
+ <classpathentry kind="src" path="/org.eclipse.ui.workbench.texteditor"/>
+ <classpathentry kind="src" path="/org.eclipse.ui.ide"/>
+ <classpathentry kind="src" path="/org.eclipse.ui.editors"/>
<classpathentry kind="src" path="/org.eclipse.core.boot"/>
- <classpathentry sourcepath="JRE_SRC" kind="var" path="JRE_LIB"/>
- <classpathentry kind="src" path="/org.eclipse.help"/>
- <classpathentry kind="src" path="/org.eclipse.ui.console"/>
- <classpathentry kind="src" path="/org.eclipse.core.variables"/>
+ <classpathentry kind="src" path="/org.eclipse.core.runtime"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="output" path="bin"/>
</classpath>
diff --git a/org.eclipse.debug.ui/.project b/org.eclipse.debug.ui/.project
index 2d33a84f1..4efd391de 100644
--- a/org.eclipse.debug.ui/.project
+++ b/org.eclipse.debug.ui/.project
@@ -9,8 +9,12 @@
<project>org.eclipse.core.variables</project>
<project>org.eclipse.debug.core</project>
<project>org.eclipse.help</project>
+ <project>org.eclipse.jface.text</project>
<project>org.eclipse.ui</project>
<project>org.eclipse.ui.console</project>
+ <project>org.eclipse.ui.editors</project>
+ <project>org.eclipse.ui.ide</project>
+ <project>org.eclipse.ui.workbench.texteditor</project>
</projects>
<buildSpec>
<buildCommand>
diff --git a/org.eclipse.debug.ui/plugin.xml b/org.eclipse.debug.ui/plugin.xml
index f3552876a..3c6175bf1 100644
--- a/org.eclipse.debug.ui/plugin.xml
+++ b/org.eclipse.debug.ui/plugin.xml
@@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.0"?>
<plugin
id="org.eclipse.debug.ui"
name="%pluginName"
@@ -19,6 +20,10 @@
<import plugin="org.eclipse.ui.console"/>
<import plugin="org.eclipse.help"/>
<import plugin="org.eclipse.debug.core"/>
+ <import plugin="org.eclipse.jface.text"/>
+ <import plugin="org.eclipse.ui.workbench.texteditor"/>
+ <import plugin="org.eclipse.ui.ide"/>
+ <import plugin="org.eclipse.ui.editors"/>
</requires>
@@ -623,11 +628,11 @@
objectClass="org.eclipse.debug.core.model.IExpression"
id="org.eclipse.debug.ui.ExpressionActions">
<visibility>
- <not>
- <objectClass
- name="org.eclipse.debug.core.model.IWatchExpression">
- </objectClass>
- </not>
+ <not>
+ <objectClass
+ name="org.eclipse.debug.core.model.IWatchExpression">
+ </objectClass>
+ </not>
</visibility>
<action
label="%convertToWatchExpressionAction.label"
@@ -991,22 +996,6 @@
id="org.eclipse.debug.ui.actions.SelectAllExpressionsAction">
</action>
</viewerContribution>
-<!-- Contributions to Console View popup menu -->
- <viewerContribution
- targetID="org.eclipse.ui.console.ConsoleView"
- id="org.eclipse.ui.console.ConsoleView.popupMenu">
- <action
- label="%TerminateAction.label"
- icon="icons/full/clcl16/terminate_co.gif"
- helpContextId="console_terminate_action_context"
- class="org.eclipse.debug.internal.ui.actions.ConsoleTerminateActionDelegate"
- menubarPath="additions"
- id="org.eclipse.debug.ui.consoleView.popupMenu.terminate">
- <selection
- class="org.eclipse.debug.core.model.ITerminate">
- </selection>
- </action>
- </viewerContribution>
</extension>
<extension
id="instructionPointer"
@@ -1263,95 +1252,91 @@
configuration="org.eclipse.ui.defaultAcceleratorConfiguration">
</keyBinding>
</extension>
-
<extension
- point="org.eclipse.ui.workbench.texteditor.markerAnnotationSpecification">
- <specification
- annotationType="org.eclipse.debug.core.breakpoint"
- label="%BreakpointMarkerPreference.label"
- markerSeverity="0"
- markerType="org.eclipse.debug.core.breakpointMarker"
- textPreferenceKey="breakpointIndication"
- textPreferenceValue="false"
- overviewRulerPreferenceKey="breakpointIndicationInOverviewRuler"
- overviewRulerPreferenceValue="true"
- colorPreferenceKey="breakpointIndicationColor"
- colorPreferenceValue="0,0,255"
- presentationLayer="3">
- </specification>
- </extension>
-
-
-<!-- Dynamic (String Substitution) Variables -->
+ point="org.eclipse.ui.editors.markerAnnotationSpecification">
+ <specification
+ colorPreferenceValue="0,0,255"
+ annotationType="org.eclipse.debug.core.breakpoint"
+ colorPreferenceKey="breakpointIndicationColor"
+ overviewRulerPreferenceValue="true"
+ markerType="org.eclipse.debug.core.breakpointMarker"
+ presentationLayer="3"
+ textPreferenceValue="false"
+ label="%BreakpointMarkerPreference.label"
+ textPreferenceKey="breakpointIndication"
+ markerSeverity="0"
+ overviewRulerPreferenceKey="breakpointIndicationInOverviewRuler">
+ </specification>
+ </extension>
+<!-- Dynamic (String Substitution) Variables -->
<extension
point="org.eclipse.core.variables.dynamicVariables">
<variable
name="workspace_loc"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.WorkspaceResolver"
- description="%workspace_loc.description">
+ description="%workspace_loc.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.WorkspaceResolver">
</variable>
<variable
name="project_loc"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver"
- description="%project_loc.description">
+ description="%project_loc.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver">
</variable>
<variable
name="project_path"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver"
- description="%project_path.description">
+ description="%project_path.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver">
</variable>
<variable
name="project_name"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver"
- description="%project_name.description">
+ description="%project_name.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ProjectResolver">
</variable>
<variable
name="resource_loc"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver"
- description="%resource_loc.description">
+ description="%resource_loc.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver">
</variable>
<variable
name="resource_path"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver"
- description="%resource_path.description">
+ description="%resource_path.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver">
</variable>
<variable
name="resource_name"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver"
- description="%resource_name.description">
+ description="%resource_name.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ResourceResolver">
</variable>
<variable
name="container_loc"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver"
- description="%container_loc.description">
+ description="%container_loc.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver">
</variable>
<variable
name="container_path"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver"
- description="%container_path.description">
+ description="%container_path.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver">
</variable>
<variable
name="container_name"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver"
- description="%container_name.description">
+ description="%container_name.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.ContainerResolver">
</variable>
<variable
name="string_prompt"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.StringPrompt"
- description="%string_prompt.description">
+ description="%string_prompt.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.StringPrompt">
</variable>
<variable
name="file_prompt"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.FilePrompt"
- description="%file_prompt.description">
+ description="%file_prompt.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.FilePrompt">
</variable>
<variable
name="folder_prompt"
- resolver="org.eclipse.debug.internal.ui.stringsubstitution.FolderPrompt"
- description="%folder_prompt.description">
- </variable>
- </extension>
-
+ description="%folder_prompt.description"
+ resolver="org.eclipse.debug.internal.ui.stringsubstitution.FolderPrompt">
+ </variable>
+ </extension>
<!-- String Variable Presentations -->
<extension
point="org.eclipse.debug.ui.stringVariablePresentations">
@@ -1366,10 +1351,9 @@
<variablePresentation
argumentSelector="org.eclipse.debug.internal.ui.stringsubstitution.ResourceSelector"
variableName="resource_name">
- </variablePresentation>
+ </variablePresentation>
</extension>
-
-<!-- Launch Config Comparators -->
+<!-- Launch Config Comparators -->
<extension
point="org.eclipse.debug.core.launchConfigurationComparators">
<launchConfigurationComparator
@@ -1378,7 +1362,6 @@
id="org.eclipse.debug.ui.workingSetComparator">
</launchConfigurationComparator>
</extension>
-
<!-- Roles and Activities -->
<extension
point="org.eclipse.ui.activities">
@@ -1394,7 +1377,7 @@
</patternBinding>
</extension>
<extension
- point="org.eclipse.ui.roles">
+ point="org.eclipse.ui.roles">
<activityBinding
activityId="org.eclipse.debugging"
roleId="org.eclipse.roles.javaRole">
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/FollowHyperlinkAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/FollowHyperlinkAction.java
index b8717b5dc..b4483922b 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/FollowHyperlinkAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/FollowHyperlinkAction.java
@@ -20,6 +20,7 @@ import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.ui.ISharedImages;
import org.eclipse.ui.actions.SelectionProviderAction;
import org.eclipse.ui.help.WorkbenchHelp;
+import org.eclipse.ui.ide.IDE;
/**
* Follows a hyperlink in the console
@@ -33,7 +34,7 @@ public class FollowHyperlinkAction extends SelectionProviderAction {
super(selectionProvider, ActionMessages.getString("FollowHyperlinkAction.&Open_Link_1")); //$NON-NLS-1$
setToolTipText(ActionMessages.getString("FollowHyperlinkAction.Follow_the_selected_hyperlink._2")); //$NON-NLS-1$
ISharedImages images= DebugUIPlugin.getDefault().getWorkbench().getSharedImages();
- setImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_OPEN_MARKER));
+ setImageDescriptor(images.getImageDescriptor(IDE.SharedImages.IMG_OPEN_MARKER));
WorkbenchHelp.setHelp(
this,
IDebugHelpContextIds.FOLLOW_CONSOLE_HYPERLINK_ACTION);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/OpenBreakpointMarkerAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/OpenBreakpointMarkerAction.java
index 34cda9b9c..62b935b9e 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/OpenBreakpointMarkerAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/OpenBreakpointMarkerAction.java
@@ -27,6 +27,7 @@ import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.actions.SelectionProviderAction;
import org.eclipse.ui.help.WorkbenchHelp;
+import org.eclipse.ui.ide.IDE;
public class OpenBreakpointMarkerAction extends SelectionProviderAction {
@@ -36,7 +37,7 @@ public class OpenBreakpointMarkerAction extends SelectionProviderAction {
super(selectionProvider, ActionMessages.getString("OpenBreakpointMarkerAction.&Go_to_File_1")); //$NON-NLS-1$
setToolTipText(ActionMessages.getString("OpenBreakpointMarkerAction.Go_to_File_for_Breakpoint_2")); //$NON-NLS-1$
ISharedImages images= DebugUIPlugin.getDefault().getWorkbench().getSharedImages();
- setImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_OPEN_MARKER));
+ setImageDescriptor(images.getImageDescriptor(IDE.SharedImages.IMG_OPEN_MARKER));
WorkbenchHelp.setHelp(
this,
IDebugHelpContextIds.OPEN_BREAKPOINT_ACTION);
@@ -75,7 +76,7 @@ public class OpenBreakpointMarkerAction extends SelectionProviderAction {
}
if (part != null) {
part.setFocus();
- part.gotoMarker(breakpoint.getMarker());
+ IDE.gotoMarker(part, breakpoint.getMarker());
}
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleDocumentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleDocumentProvider.java
index 86da1dbb7..f16da8d88 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleDocumentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ConsoleDocumentProvider.java
@@ -16,8 +16,12 @@ import org.eclipse.debug.core.model.IProcess;
import org.eclipse.debug.internal.ui.DebugUIPlugin;
import org.eclipse.debug.ui.console.ConsoleColorProvider;
import org.eclipse.debug.ui.console.IConsoleColorProvider;
+
+import org.eclipse.jface.operation.IRunnableContext;
import org.eclipse.jface.text.IDocument;
import org.eclipse.jface.text.source.IAnnotationModel;
+
+import org.eclipse.ui.editors.text.WorkspaceOperationRunner;
import org.eclipse.ui.texteditor.AbstractDocumentProvider;
/**
@@ -25,6 +29,12 @@ import org.eclipse.ui.texteditor.AbstractDocumentProvider;
* which is connected to the streams proxy of the associated process.
*/
public class ConsoleDocumentProvider extends AbstractDocumentProvider {
+
+ /**
+ * The runnable context for that provider.
+ * @since 3.0
+ */
+ private WorkspaceOperationRunner fOperationRunner;
/**
* @see org.eclipse.ui.texteditor.AbstractDocumentProvider#createDocument(java.lang.Object)
@@ -107,4 +117,14 @@ public class ConsoleDocumentProvider extends AbstractDocumentProvider {
private ConsoleDocumentManager getConsoleDocumentManager() {
return DebugUIPlugin.getDefault().getConsoleDocumentManager();
}
+
+ /*
+ * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getOperationRunner(org.eclipse.core.runtime.IProgressMonitor)
+ */
+ protected IRunnableContext getOperationRunner(IProgressMonitor monitor) {
+ if (fOperationRunner == null)
+ fOperationRunner = new WorkspaceOperationRunner();
+ fOperationRunner.setProgressMonitor(monitor);
+ return fOperationRunner;
+ }
} \ No newline at end of file
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsolePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsolePage.java
index 73c7d31ae..98e8d7ad1 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsolePage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsolePage.java
@@ -56,6 +56,7 @@ import org.eclipse.ui.ISharedImages;
import org.eclipse.ui.IWorkbenchActionConstants;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.console.IConsoleConstants;
import org.eclipse.ui.console.IConsoleView;
import org.eclipse.ui.console.actions.ClearOutputAction;
@@ -174,18 +175,18 @@ public class ProcessConsolePage implements IPageBookViewPage, ISelectionListener
return;
}
if (doc.isReadOnly()) {
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.COPY));
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.SELECT_ALL));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.COPY.getId()));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.SELECT_ALL.getId()));
} else {
- updateAction(IWorkbenchActionConstants.PASTE);
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.CUT));
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.COPY));
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.PASTE));
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.SELECT_ALL));
+ updateAction(ActionFactory.PASTE.getId());
+ menu.add((IAction)fGlobalActions.get(ActionFactory.CUT.getId()));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.COPY.getId()));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.PASTE.getId()));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.SELECT_ALL.getId()));
}
menu.add(new Separator("FIND")); //$NON-NLS-1$
- menu.add((IAction)fGlobalActions.get(IWorkbenchActionConstants.FIND));
+ menu.add((IAction)fGlobalActions.get(ActionFactory.FIND.getId()));
menu.add((IAction)fGlobalActions.get(ITextEditorActionConstants.GOTO_LINE));
fFollowLinkAction.setEnabled(fFollowLinkAction.getHyperLink() != null);
menu.add(fFollowLinkAction);
@@ -261,26 +262,26 @@ public class ProcessConsolePage implements IPageBookViewPage, ISelectionListener
action.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_CUT));
action.setDisabledImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_CUT_DISABLED));
action.setHoverImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_CUT_HOVER));
- setGlobalAction(actionBars, IWorkbenchActionConstants.CUT, action);
+ setGlobalAction(actionBars, ActionFactory.CUT.getId(), action);
action= new TextViewerAction(getConsoleViewer(), ITextOperationTarget.COPY);
action.configureAction(DebugUIViewsMessages.getString("ConsoleView.&Copy@Ctrl+C_6"), DebugUIViewsMessages.getString("ConsoleView.Copy_7"), DebugUIViewsMessages.getString("ConsoleView.Copy_7")); //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
action.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_COPY));
action.setDisabledImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_COPY_DISABLED));
action.setHoverImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_COPY_HOVER));
- setGlobalAction(actionBars, IWorkbenchActionConstants.COPY, action);
+ setGlobalAction(actionBars, ActionFactory.COPY.getId(), action);
action= new TextViewerAction(getConsoleViewer(), ITextOperationTarget.PASTE);
action.configureAction(DebugUIViewsMessages.getString("ConsoleView.&Paste@Ctrl+V_9"), DebugUIViewsMessages.getString("ConsoleView.Paste_10"), DebugUIViewsMessages.getString("ConsoleView.Paste_Clipboard_Text_11")); //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
action.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_PASTE));
action.setDisabledImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_PASTE_DISABLED));
action.setHoverImageDescriptor(PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(ISharedImages.IMG_TOOL_PASTE_HOVER));
- setGlobalAction(actionBars, IWorkbenchActionConstants.PASTE, action);
+ setGlobalAction(actionBars, ActionFactory.PASTE.getId(), action);
action= new TextViewerAction(getConsoleViewer(), ITextOperationTarget.SELECT_ALL);
action.configureAction(DebugUIViewsMessages.getString("ConsoleView.Select_&All@Ctrl+A_12"), DebugUIViewsMessages.getString("ConsoleView.Select_All"), DebugUIViewsMessages.getString("ConsoleView.Select_All")); //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- setGlobalAction(actionBars, IWorkbenchActionConstants.SELECT_ALL, action);
+ setGlobalAction(actionBars, ActionFactory.SELECT_ALL.getId(), action);
//XXX Still using "old" resource access
ResourceBundle bundle= ResourceBundle.getBundle("org.eclipse.debug.internal.ui.views.DebugUIViewsMessages"); //$NON-NLS-1$
- setGlobalAction(actionBars, IWorkbenchActionConstants.FIND, new FindReplaceAction(bundle, "find_replace_action.", getConsoleView())); //$NON-NLS-1$
+ setGlobalAction(actionBars, ActionFactory.FIND.getId(), new FindReplaceAction(bundle, "find_replace_action.", getConsoleView())); //$NON-NLS-1$
action= new TextViewerGotoLineAction(getConsoleViewer());
setGlobalAction(actionBars, ITextEditorActionConstants.GOTO_LINE, action);
@@ -312,10 +313,10 @@ public class ProcessConsolePage implements IPageBookViewPage, ISelectionListener
fTerminate = new ConsoleTerminateAction(getConsole());
DebugPlugin.getDefault().addDebugEventListener(this);
- fSelectionActions.add(IWorkbenchActionConstants.CUT);
- fSelectionActions.add(IWorkbenchActionConstants.COPY);
- fSelectionActions.add(IWorkbenchActionConstants.PASTE);
- fSelectionActions.add(IWorkbenchActionConstants.FIND);
+ fSelectionActions.add(ActionFactory.CUT.getId());
+ fSelectionActions.add(ActionFactory.COPY.getId());
+ fSelectionActions.add(ActionFactory.PASTE.getId());
+ fSelectionActions.add(ActionFactory.FIND.getId());
}
protected void updateSelectionDependentActions() {
@@ -472,7 +473,7 @@ public class ProcessConsolePage implements IPageBookViewPage, ISelectionListener
*/
public void textChanged(TextEvent event) {
// update the find replace action if the document length is > 0
- IUpdate findReplace = (IUpdate)fGlobalActions.get(IWorkbenchActionConstants.FIND);
+ IUpdate findReplace = (IUpdate)fGlobalActions.get(ActionFactory.FIND.getId());
if (findReplace != null) {
findReplace.update();
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
index 7c1e59617..8daa66ade 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
@@ -96,6 +96,7 @@ import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.dialogs.PropertyDialogAction;
+import org.eclipse.ui.ide.IDE;
import org.eclipse.ui.part.IShowInSource;
import org.eclipse.ui.part.IShowInTarget;
import org.eclipse.ui.part.IShowInTargetList;
@@ -700,7 +701,7 @@ public class LaunchView extends AbstractDebugEventHandlerView implements ISelect
} else {
IMarker marker= getInstructionPointer(lineNumber, charStart, charEnd);
if (marker != null) {
- editor.gotoMarker(marker);
+ IDE.gotoMarker(editor, marker);
}
}
}
@@ -767,7 +768,7 @@ public class LaunchView extends AbstractDebugEventHandlerView implements ISelect
lineNumber++;
IMarker marker= getInstructionPointer(lineNumber, charStart, charEnd);
if (marker != null) {
- editor.gotoMarker(marker);
+ IDE.gotoMarker(editor, marker);
// add decoration
Decoration decoration = new MarkerTextSelection(editor, lineNumber, thread);
DecorationManager.addDecoration(decoration);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
index aee218f7a..a1d3cbe40 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
@@ -97,6 +97,7 @@ import org.eclipse.ui.INullSelectionListener;
import org.eclipse.ui.ISelectionListener;
import org.eclipse.ui.IWorkbenchActionConstants;
import org.eclipse.ui.IWorkbenchPart;
+import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.console.actions.TextViewerAction;
import org.eclipse.ui.texteditor.FindReplaceAction;
import org.eclipse.ui.texteditor.ITextEditorActionDefinitionIds;
@@ -318,8 +319,8 @@ public class VariablesView extends AbstractDebugEventHandlerView implements ISel
protected static final String DETAIL_SELECT_ALL_ACTION = SELECT_ALL_ACTION + ".Detail"; //$NON-NLS-1$
protected static final String VARIABLES_SELECT_ALL_ACTION= SELECT_ALL_ACTION + ".Variables"; //$NON-NLS-1$
- protected static final String DETAIL_COPY_ACTION = IWorkbenchActionConstants.COPY + ".Detail"; //$NON-NLS-1$
- protected static final String VARIABLES_COPY_ACTION= IWorkbenchActionConstants.COPY + ".Variables"; //$NON-NLS-1$
+ protected static final String DETAIL_COPY_ACTION = ActionFactory.COPY.getId() + ".Detail"; //$NON-NLS-1$
+ protected static final String VARIABLES_COPY_ACTION= ActionFactory.COPY.getId() + ".Variables"; //$NON-NLS-1$
protected static final String LOGICAL_STRUCTURE_TYPE_PREFIX = "VAR_LS_"; //$NON-NLS-1$
@@ -784,20 +785,20 @@ public class VariablesView extends AbstractDebugEventHandlerView implements ISel
textAction= new TextViewerAction(getDetailViewer(), ITextOperationTarget.CUT);
textAction.configureAction(VariablesViewMessages.getString("VariablesView.Cu&t_11"), "", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- setAction(IWorkbenchActionConstants.CUT, textAction);
+ setAction(ActionFactory.CUT.getId(), textAction);
textAction= new TextViewerAction(getDetailViewer(), ITextOperationTarget.PASTE);
textAction.configureAction(VariablesViewMessages.getString("VariablesView.&Paste_14"), "", ""); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
- setAction(IWorkbenchActionConstants.PASTE, textAction);
+ setAction(ActionFactory.PASTE.getId(), textAction);
//XXX Still using "old" resource access
ResourceBundle bundle= ResourceBundle.getBundle("org.eclipse.debug.internal.ui.views.variables.VariablesViewMessages"); //$NON-NLS-1$
- setAction(IWorkbenchActionConstants.FIND, new FindReplaceAction(bundle, "find_replace_action.", this)); //$NON-NLS-1$
+ setAction(ActionFactory.FIND.getId(), new FindReplaceAction(bundle, "find_replace_action.", this)); //$NON-NLS-1$
- fSelectionActions.add(IWorkbenchActionConstants.COPY);
- fSelectionActions.add(IWorkbenchActionConstants.CUT);
- fSelectionActions.add(IWorkbenchActionConstants.PASTE);
- updateAction(IWorkbenchActionConstants.FIND);
+ fSelectionActions.add(ActionFactory.COPY.getId());
+ fSelectionActions.add(ActionFactory.CUT.getId());
+ fSelectionActions.add(ActionFactory.PASTE.getId());
+ updateAction(ActionFactory.FIND.getId());
// set initial content here, as viewer has to be set
setInitialContent();
@@ -863,12 +864,12 @@ public class VariablesView extends AbstractDebugEventHandlerView implements ISel
menu.add(new Separator(IDebugUIConstants.VARIABLE_GROUP));
menu.add(getAction("ContentAssist")); //$NON-NLS-1$
menu.add(new Separator());
- menu.add(getAction(IWorkbenchActionConstants.CUT));
- menu.add(getAction(IWorkbenchActionConstants.COPY + ".Detail")); //$NON-NLS-1$
- menu.add(getAction(IWorkbenchActionConstants.PASTE));
+ menu.add(getAction(ActionFactory.CUT.getId()));
+ menu.add(getAction(ActionFactory.COPY.getId() + ".Detail")); //$NON-NLS-1$
+ menu.add(getAction(ActionFactory.PASTE.getId()));
menu.add(getAction(DETAIL_SELECT_ALL_ACTION));
menu.add(new Separator("FIND")); //$NON-NLS-1$
- menu.add(getAction(IWorkbenchActionConstants.FIND));
+ menu.add(getAction(ActionFactory.FIND.getId()));
menu.add(new Separator(IWorkbenchActionConstants.MB_ADDITIONS));
}
@@ -1036,7 +1037,7 @@ public class VariablesView extends AbstractDebugEventHandlerView implements ISel
public void documentAboutToBeChanged(DocumentEvent event) {
}
public void documentChanged(DocumentEvent event) {
- updateAction(IWorkbenchActionConstants.FIND);
+ updateAction(ActionFactory.FIND.getId());
}
};
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugView.java
index 1690c79ed..123606a5b 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugView.java
@@ -15,7 +15,7 @@ import org.eclipse.jface.action.IAction;
import org.eclipse.jface.action.IMenuManager;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.ui.IViewPart;
-import org.eclipse.ui.IWorkbenchActionConstants;
+import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.texteditor.IUpdate;
/**
@@ -43,7 +43,7 @@ public interface IDebugView extends IViewPart {
*
* @see #setAction(String, IAction)
*/
- public static final String COPY_ACTION = IWorkbenchActionConstants.COPY;
+ public static final String COPY_ACTION = ActionFactory.COPY.getId();
/**
* Action id for a view's cut action. Any view
@@ -53,7 +53,7 @@ public interface IDebugView extends IViewPart {
*
* @see #setAction(String, IAction)
*/
- public static final String CUT_ACTION = IWorkbenchActionConstants.CUT;
+ public static final String CUT_ACTION = ActionFactory.CUT.getId();
/**
* Action id for a view's double-click action. Any view
@@ -73,7 +73,7 @@ public interface IDebugView extends IViewPart {
*
* @see #setAction(String, IAction)
*/
- public static final String FIND_ACTION = IWorkbenchActionConstants.FIND;
+ public static final String FIND_ACTION = ActionFactory.FIND.getId();
/**
* Action id for a view's paste action. Any view
@@ -83,7 +83,7 @@ public interface IDebugView extends IViewPart {
*
* @see #setAction(String, IAction)
*/
- public static final String PASTE_ACTION = IWorkbenchActionConstants.PASTE;
+ public static final String PASTE_ACTION = ActionFactory.PASTE.getId();
/**
* Action id for a view's remove action. Any view
@@ -103,7 +103,7 @@ public interface IDebugView extends IViewPart {
*
* @see #setAction(String, IAction)
*/
- public static final String SELECT_ALL_ACTION = IWorkbenchActionConstants.SELECT_ALL;
+ public static final String SELECT_ALL_ACTION = ActionFactory.SELECT_ALL.getId();
/**
* Returns the viewer contained in this debug view.
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/console/FileLink.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/console/FileLink.java
index c5abf9c95..c8bdf45a1 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/console/FileLink.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/console/FileLink.java
@@ -21,6 +21,7 @@ import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.part.FileEditorInput;
import org.eclipse.ui.texteditor.IDocumentProvider;
import org.eclipse.ui.texteditor.ITextEditor;
@@ -69,7 +70,7 @@ public class FileLink implements IConsoleHyperlink {
IWorkbenchPage page = window.getActivePage();
if (page != null) {
try {
- IEditorPart editorPart = page.openEditor(fFile, fEditorId, false);
+ IEditorPart editorPart = page.openEditor(new FileEditorInput(fFile), fEditorId, false);
if (fFileLineNumber > 0 && editorPart instanceof ITextEditor) {
ITextEditor textEditor = (ITextEditor)editorPart;
IEditorInput input = editorPart.getEditorInput();

Back to the top