Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-ui-dev] keybinding problem

Can't get a response on the newsgroup, hope can get an answer here.   //jml

hi,
I am trying to create a toolbar icon that commit to cvs the current selected
element. And I also want to bind a key shortcut for it.

I can make the toolbar work, but I can't make the key binding work.
Following is the plugin.xml file, someone please help.
Thanks
jml

<?xml version="1.0" encoding="UTF-8"?>
<plugin
   id="myext"
   name="myext"
   version="1.0.0">
   <runtime>
      <library name="myext.jar"/>
   </runtime>
   <requires>
      <import plugin="org.eclipse.team.ui"/>
      <import plugin="org.eclipse.team.cvs.ui"/>
      <import plugin="org.eclipse.ui"/>
   </requires>
     <extension point="org.eclipse.ui.acceleratorSets">
      <acceleratorSet
        configurationId="myext.acceleratorSets"
        scopeId="org.eclipse.ui.globalScope">
          <accelerator
              id="myext.cvs.commit"
              key="CTRL+0">
          </accelerator>
      </acceleratorSet>
   </extension>
   <extension point="org.eclipse.ui.actionDefinitions">
    <actionDefinition id="myext.cvs.commit" />
   </extension>
   <extension
         point="org.eclipse.ui.actionSets">
      <actionSet
            label="My Ext"
            description="my extension"
            visible="true"
            id="myext.actionSets">
         <action
             definitionId="myext.cvs.commit"
               label="Commit Current"
               tooltip="Commit current"
               class="myext.actions.CVSCommitAction"
               toolbarPath="Normal/myext"
               id="myext.commit"
               accelerator="Ctrl+0">
         </action>
      </actionSet>
   </extension>
</plugin>

Back to the top