<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    posts - 36, comments - 30, trackbacks - 0, articles - 3
    擴(kuò)展點(diǎn):
    org.eclipse.ui.menus(確定菜單創(chuàng)建的區(qū)域)
    org.eclipse.ui.commands
    org.eclipse.ui.handlers(command的具體行為)
    org.eclipse.ui.commandImages(comand的圖片)

    擴(kuò)展點(diǎn)org.eclipse.ui.menus用來對(duì)菜單進(jìn)行擴(kuò)展,可以對(duì)主菜單,工具欄,上下文菜單進(jìn)行擴(kuò)展。

    示例代碼如下:
    <extension
             
    point="org.eclipse.ui.menus">
          
    <menuContribution
                
    allPopups="false"
                locationURI
    ="menu:org.eclipse.ui.main.menu?after=additions">
             
    <command
                   
    commandId="com.xxxx.test.command1"
                   style
    ="push">
             
    </command>
          
    </menuContribution>
    </extension>

    其中l(wèi)ocationURI屬性指定菜單擴(kuò)展的位置,上述代碼是對(duì)主菜單進(jìn)行擴(kuò)展,如果要對(duì)工具欄和上下文菜單進(jìn)行擴(kuò)展,書寫格式如下:

    toolbar:org.eclipse.ui.main.toolbar?after=additions
    popup:org.eclipse.ui.popup.any?after=additions(上下文菜單在任何位置出現(xiàn))
    popup:org.eclipse.ui.views.ProblemView?after=additions(上下文菜單在問題視圖中出現(xiàn))

    commandId屬性指定該menu對(duì)應(yīng)的command,一個(gè)menu可以對(duì)應(yīng)多個(gè)command。

    command可以通過擴(kuò)展點(diǎn)org.eclipse.ui.commands擴(kuò)展,示例代碼如下:

    <extension
             
    point="org.eclipse.ui.commands">
    <category
                
    id="com.xxxx.test.category1"
                name
    ="MenuTest">
          
    </category>

          
    <command
    categoryId="="com.xxxx.test.category1"
                id
    ="com.xxxx.test.command1"
                name
    ="CommandA">
          
    </command>
     
    </extension>

    至于Command具體要做什么,需要通過擴(kuò)展點(diǎn)org.eclipse.ui.handlers來指定,示例代碼如下:

    <extension
             
    point="org.eclipse.ui.handlers">
          
    <handler
                
    class="com.xxxx.test.SampleHandler"
                commandId
    ="com.xxxx.test.command1">
          
    </handler>
     
    </extension>

    還有擴(kuò)展點(diǎn)org.eclipse.ui.commandImages,可以指定Command對(duì)應(yīng)的圖標(biāo)。

     <extension
             
    point="org.eclipse.ui.commandImages">
          
    <image
                
    commandId="com.xxxx.test.command1"
                icon
    ="icons/sample.gif">
          
    </image>
      
    </extension>

    主站蜘蛛池模板: 国产成人无码免费看片软件| 黄色网址大全免费| 美女内射毛片在线看免费人动物| 亚洲AV无码成人精品区狼人影院| 亚洲一级特黄特黄的大片| 无码国产精品一区二区免费vr| 色吊丝永久在线观看最新免费| 国产精品亚洲精品日韩已方| 免费无码婬片aaa直播表情| 又爽又黄无遮挡高清免费视频| 亚洲精选在线观看| 国产成人精品免费视频大全麻豆 | 一级毛片高清免费播放| 亚洲AV伊人久久青青草原| a毛片成人免费全部播放| 亚洲综合色成在线播放| 国产一级黄片儿免费看| 久久精品国产亚洲av日韩| 免费国产成人高清在线观看网站| 国产亚洲精品拍拍拍拍拍| 99视频在线观看免费| 亚洲色图.com| 国产精品深夜福利免费观看| 有码人妻在线免费看片| 久久被窝电影亚洲爽爽爽| 97热久久免费频精品99 | 亚洲第一精品在线视频| 99热在线观看免费| 久久亚洲最大成人网4438| 亚洲av午夜精品一区二区三区| 亚洲第一成年免费网站| 又大又粗又爽a级毛片免费看| 亚洲一区在线视频观看| 免费在线观看黄色毛片| 美丽姑娘免费观看在线观看中文版 | 中出五十路免费视频| 亚洲av无码不卡久久| 四虎AV永久在线精品免费观看| 亚洲一区精彩视频| 2022中文字字幕久亚洲| 91成人免费观看网站|