0 Replies Latest reply on Jun 28, 2010 11:33 PM by coolshare

    The targetID for mxml editor

    coolshare

      I tried to add a popup menu on the mxml editor using sample code (from

      http://www.eclipse.org/articles/article.php?file=Article-action-contribution/index.html#Ru nning%20the%20examples)

       

      <extension
            point="org.eclipse.ui.popupMenus">
         <viewerContribution
               id="org.eclipse.ui.articles.action.contribution.viewerContribution1"
               targetID="com.adobe.flexbuilder.editors.mxml.MXMLEditor">
            <action
                  class="org.eclipse.ui.articles.action.contribution.EditorAction1Delegate"
                  helpContextId="org.eclipse.ui.articles.action.contribution.action1"
                  icon="icons/red_dot.gif"
                  id="org.eclipse.ui.articles.action.contribution.action1"
                  label="Binding"
                  menubarPath="additions">
            </action>
         </viewerContribution>
      </extension>

       

      If I changed  targetID="com.adobe.flexbuilder.editors.mxml.MXMLEditor" to

      targetID="#TextEditorContext", it shows up within a text editor.

       

      It seems that my targetID is wrong. But the mxml editor does usethe id

       

       

      <editor class="com.adobe.flexbuilder.mxml.editor.MXMLEditor" icon="icons/fb_mxml_16x16.png" contributorClass="com.adobe.flexbuilder.mxml.editor.MXMLEditorContributor" name="%editors.mxml.MXMLEditor" id="com.adobe.flexbuilder.editors.mxml.MXMLEditor" default="true" extensions="mxml">
      <contentTypeBinding contentTypeId="com.adobe.flexbuilder.project.content-type-mxml" />
      </editor>

      What should I use as the targetID in order to be trigged by right clicking on the mxml editor?

      thanks

      mark