<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
   <extension
         point="org.eclipse.ui.commands">
      <command
            categoryId="org.eclipse.ui.category.file"
            defaultHandler="com.archimatetool.templates.impl.NewArchimateModelFromTemplateHandler"
            description="%command.description"
            id="com.archimatetool.templates.modelFromTemplate"
            name="%command.name">
      </command>
      <command
            categoryId="org.eclipse.ui.category.file"
            description="%command.description.0"
            id="com.archimatetool.templates.saveAsTemplate"
            name="%command.name.0">
      </command>
   </extension>
   <extension
         point="org.eclipse.ui.commandImages">
      <image
            commandId="com.archimatetool.templates.modelFromTemplate"
            icon="img/newfile_wiz.png">
      </image>
   </extension>
   <extension
         point="org.eclipse.ui.menus">
      <menuContribution
            allPopups="false"
            locationURI="menu:new_menu?after=new_menu.ext">
         <command
               commandId="com.archimatetool.templates.modelFromTemplate"
               icon="img/newfile_wiz.png"
               label="%action.label"
               style="push">
         </command>
      </menuContribution>
      <menuContribution
            allPopups="false"
            locationURI="menu:com.archimatetool.menu.newDropdown">
         <command
               commandId="com.archimatetool.templates.modelFromTemplate"
               icon="img/newfile_wiz.png"
               label="%action.label"
               style="push">
         </command>
      </menuContribution>
      <menuContribution
            allPopups="false"
            locationURI="menu:file?after=save.ext">
         <command
               commandId="com.archimatetool.templates.saveAsTemplate"
               label="%action.label.0"
               style="push">
         </command>
      </menuContribution>
   </extension>
   <extension
         point="org.eclipse.ui.handlers">
      <handler
            class="com.archimatetool.templates.impl.SaveAsTemplateHandler"
            commandId="com.archimatetool.templates.saveAsTemplate">
         <enabledWhen>
            <reference
                  definitionId="com.archimatetool.modelEnabled">
            </reference>
         </enabledWhen>
      </handler>
   </extension>

</plugin>
