Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoritrimble2011-01-04 15:15:24 -0500
committeritrimble2011-01-04 15:15:24 -0500
commita91b69a7be4047ac652a60a2fc2d33ad2f8b6a98 (patch)
tree7509941458fa4213fcd681d938d45169db4b5701
parent3fa1aa0efc2a4a58e8154d22954a6a1e38624f38 (diff)
downloadwebtools.jsf-a91b69a7be4047ac652a60a2fc2d33ad2f8b6a98.tar.gz
webtools.jsf-a91b69a7be4047ac652a60a2fc2d33ad2f8b6a98.tar.xz
webtools.jsf-a91b69a7be4047ac652a60a2fc2d33ad2f8b6a98.zip
Bug 191494 - Unable to switch pages in faces config editor without mouse
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties4
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java8
3 files changed, 37 insertions, 0 deletions
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties
index f8d99a513..04d71098c 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties
+++ b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties
@@ -58,3 +58,7 @@ cheatsheet.jsf.facesconfig.title=Faces Configuration Editor
#preference page
preferencepage.jsffacesconfigui.name=FacesConfig Editor
+
+# Key Binding Context
+editor.binding.context.name=In Faces Config Editor
+editor.binding.context.description=Key binding context when using the Faces Config Editor
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml
index be992240f..02e04939f 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml
+++ b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml
@@ -106,4 +106,29 @@
label="%propertyTab.general"/>
</propertyTabs>
</extension>-->
+
+ <!-- Context for Faces Config Editor. This is activated in FacesConfigEditor.init() -->
+ <extension point="org.eclipse.ui.contexts">
+ <context description="%editor.binding.context.description"
+ id="org.eclipse.jst.jsf.facesconfig.editorContext"
+ name="%editor.binding.context.name"
+ parentId="org.eclipse.ui.textEditorScope" />
+ </extension>
+
+ <!-- Key-binding for Next Page in the multi-page Faces Config Editor -->
+ <extension point="org.eclipse.ui.bindings">
+ <key sequence="M1+F5"
+ commandId="org.eclipse.ui.part.nextPage"
+ contextId="org.eclipse.jst.jsf.facesconfig.editorContext"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration" />
+ </extension>
+
+ <!-- Key-binding for Previous Page in the multi-page Facesd Config Editor -->
+ <extension point="org.eclipse.ui.bindings">
+ <key sequence="M1+M2+F5"
+ commandId="org.eclipse.ui.part.previousPage"
+ contextId="org.eclipse.jst.jsf.facesconfig.editorContext"
+ schemeId="org.eclipse.ui.defaultAcceleratorConfiguration" />
+ </extension>
+
</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java
index 15db4c017..fd07e6ee2 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java
+++ b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java
@@ -91,6 +91,7 @@ import org.eclipse.ui.IFileEditorInput;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.actions.WorkspaceModifyOperation;
+import org.eclipse.ui.contexts.IContextService;
import org.eclipse.ui.dialogs.SaveAsDialog;
import org.eclipse.ui.forms.editor.FormEditor;
import org.eclipse.ui.forms.editor.FormPage;
@@ -356,6 +357,13 @@ public class FacesConfigEditor extends FormEditor implements
return;
}
+ //Bug 191494 - Unable to switch pages in faces config editor without mouse
+ // Activate plugin context
+ IContextService contextService = (IContextService) getSite()
+ .getService(IContextService.class);
+ contextService
+ .activateContext("org.eclipse.jst.jsf.facesconfig.editorContext"); //$NON-NLS-1$
+
createActions();
ResourcesPlugin.getWorkspace().addResourceChangeListener(

Back to the top