Set Visibility according to CdmStore connection
[taxeditor.git] / eu.etaxonomy.taxeditor.editor / plugin.xml
index 3c5382273559cd4df1926afacf919f9792fb85ab..57544a9403d7a9b1bb09eb25dd1bc4ac1506d83f 100644 (file)
             id="eu.etaxonomy.taxeditor.editor.view.checklist.ChecklistEditor"
             name="%editor.name.8">
       </editor>
-      <editor
-            class="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor"
-            default="false"
-            id="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor"
-            name="Alignment Editor">
-      </editor>
    </extension>
       <extension
-            id="eu.etaxonomy.taxeditor.editor.molecular.PherogramView"
             point="org.eclipse.ui.views">
          <view
                allowMultiple="false"
                id="eu.etaxonomy.taxeditor.editor.view.validation.problems"
                name="%view.name.6">
          </view>
-         <view
-               allowMultiple="true"
-               class="eu.etaxonomy.taxeditor.editor.molecular.PherogramViewPart"
-               id="eu.etaxonomy.taxeditor.editor.molecular.PherogramView"
-               name="PherogramView"
-               restorable="true">
-         </view>
       </extension>
       <!-- VALIDATION RELATED STUFF -->
        <extension point="org.eclipse.core.resources.markers" name="%extension.name.0" id="eu.etaxonomy.taxeditor.markers.validationerror">
                commandId="eu.etaxonomy.taxeditor.editor.command.new.name"
                label="%command.label.46"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="eu.etaxonomy.taxeditor.editor.command.new.reference"
                label="%command.label.47"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="eu.etaxonomy.taxeditor.editor.command.new.team"
                label="%command.label.1"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="eu.etaxonomy.taxeditor.editor.command.new.person"
                label="%command.label.2"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <separator
                name="eu.etaxonomy.navigation.menu.new.separator2"
                commandId="eu.etaxonomy.taxeditor.editor.command.new.specimen"
                label="%command.label.3"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <separator
                name="eu.etaxonomy.navigation.menu.new.separator3"
                commandId="eu.etaxonomy.taxeditor.editor.command.new.datasource"
                label="%command.label.48"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
       </menuContribution>
       <menuContribution
                   name="org.eclipse.ui.views.showView.viewId"
                   value="eu.etaxonomy.taxeditor.editor.view.descriptive">
             </parameter>
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="org.eclipse.ui.views.showView"
                   name="org.eclipse.ui.views.showView.viewId"
                   value="eu.etaxonomy.taxeditor.editor.view.media">
             </parameter>
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="org.eclipse.ui.views.showView"
                   name="org.eclipse.ui.views.showView.viewId"
                   value="eu.etaxonomy.taxeditor.editor.view.concept">
             </parameter>
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
          <command
                commandId="org.eclipse.ui.views.showView"
                   value="eu.etaxonomy.taxeditor.editor.view.concept.graph">
             </parameter>
             <visibleWhen
-                  checkEnabled="false">
-               <reference
-                     definitionId="isShowExperimentalFeatures">
-               </reference>
+                  checkEnabled="true">
+               <and>
+                  <reference
+                        definitionId="isShowExperimentalFeatures">
+                  </reference>
+                  <reference
+                        definitionId="isCdmStoreConnected">
+                  </reference>
+               </and>
             </visibleWhen>
          </command>
-         <command
-               commandId="eu.etaxonomy.taxeditor.editor.handler.OpenAlignmentEditor"
-               label="Alignment Editor"
-               style="push">
-         </command>
       </menuContribution>
       <menuContribution
             locationURI="menu:org.eclipse.ui.main.menu.navigate">
                commandId="eu.etaxonomy.taxeditor.editor.command.openParent"
                label="%command.label.8"
                style="push">
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
       </menuContribution>
       <menuContribution
                label="%command.label.54"
                style="push">
          </command>
-         <command
-               commandId="eu.etaxonomy.taxeditor.editor.editSequence"
-               label="Edit Sequence"
-               style="push">
-            <visibleWhen
-                  checkEnabled="true">
-               <reference
-                     definitionId="isSequence">
-               </reference>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="eu.etaxonomy.taxeditor.editor.showPherogram"
-               label="Show Pherogram"
-               style="push">
-            <visibleWhen
-                  checkEnabled="true">
-               <reference
-                     definitionId="isSingleRead">
-               </reference>
-            </visibleWhen>
-         </command>
          <dynamic
                class="eu.etaxonomy.taxeditor.editor.view.derivate.contextMenu.DerivateViewContextMenu"
                id="eu.etaxonomy.taxeditor.editor.view.derivate.DerivateContextMenu">
             </visibleWhen>
          </command>
       </menuContribution>
-      <menuContribution
-            allPopups="false"
-            locationURI="menu:org.eclipse.ui.main.menu">
-         <menu
-               label="Alignment Editor">
-            <command
-                  commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.loadPherogram"
-                  label="Load Pherogram"
-                  style="push">
-            </command>
-            <visibleWhen
-                  checkEnabled="true">
-               <with
-                     variable="activePartId">
-                  <equals
-                        value="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor">
-                  </equals>
-               </with>
-            </visibleWhen>
-         </menu>
-      </menuContribution>
-      <menuContribution
-            locationURI="toolbar:org.eclipse.ui.main.toolbar?after=eu.etaxonomy.taxeditor.navigation.search.toolbar">
-         <toolbar
-               id="eu.etaxonomy.taxeditor.editor.alignmentToolbar">
-            <command
-                  commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleInsertOverwrite"
-                  label="Toggle insert/overwrite"
-                  style="push">
-               <visibleWhen
-                     checkEnabled="true">
-                  <with
-                        variable="activePartId">
-                     <equals
-                           value="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor">
-                     </equals>
-                  </with>
-               </visibleWhen>
-            </command>
-            <command
-                  commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleLeftRightInsertion"
-                  icon="icons/pherogram-insert-left-16x16.png"
-                  style="push">
-               <visibleWhen
-                     checkEnabled="false">
-                  <with
-                        variable="activePartId">
-                     <equals
-                           value="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor">
-                     </equals>
-                  </with>
-               </visibleWhen>
-            </command>
-         </toolbar>
-      </menuContribution>
       
       <menuContribution
             allPopups="false"
                   name="org.eclipse.ui.views.showView.viewId"
                   value="eu.etaxonomy.taxeditor.editor.view.validation.problems">
             </parameter>
+            <visibleWhen
+                  checkEnabled="true">
+               <reference
+                     definitionId="isCdmStoreConnected">
+               </reference>
+            </visibleWhen>
          </command>
       </menuContribution>
    </extension>
             class="eu.etaxonomy.taxeditor.editor.handler.OpenChecklistEditorHandler"
             commandId="eu.etaxonomy.taxeditor.editor.handler.OpenChecklistEditorHandler">
       </handler>
-      <handler
-            class="eu.etaxonomy.taxeditor.editor.handler.LoadPherogramHandler"
-            commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.loadPherogram">
-         <activeWhen>
-            <with
-                  variable="activePartId">
-               <equals
-                     value="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor">
-               </equals>
-            </with>
-         </activeWhen>
-      </handler>
       <handler
             class="eu.etaxonomy.taxeditor.editor.view.derivate.handler.DeleteDerivateHandler"
             commandId="eu.etaxonomy.taxeditor.editor.view.derivate.command.delete">
             class="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.ToggleShowOnlyIndividualAssociationsHandler"
             commandId="eu.etaxonomy.taxeditor.editor.handler.showOnlyIndividualAssociations">
       </handler>
-      <handler
-            class="eu.etaxonomy.taxeditor.editor.handler.alignmenteditor.ToggleInsertOverwriteHandler"
-            commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleInsertOverwrite">
-      </handler>
-      <handler
-            class="eu.etaxonomy.taxeditor.editor.handler.alignmenteditor.ToggleLeftRightInsertionHandler"
-            commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleLeftRightInsertion">
-      </handler>
    </extension>
    <extension
          name="%extension.name"
             id="eu.etaxonomy.taxeditor.editor.command.new.datasource"
             name="%command.name.39">
       </command>
-      <command
-            defaultHandler="eu.etaxonomy.taxeditor.editor.handler.OpenAlignmentEditorHandler"
-            id="eu.etaxonomy.taxeditor.editor.handler.OpenAlignmentEditor"
-            name="Open Alignment Editor">
-      </command>
-      <command
-            id="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.loadPherogram"
-            name="Load Pherogram">
-      </command>
       <command
             id="eu.etaxonomy.taxeditor.editor.handler.showOnlyIndividualAssociations"
             name="%command.name.41">
       </command>
-      <command
-            id="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleInsertOverwrite"
-            name="Toggle insert/overwrite">
-      </command>
-      <command
-            id="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.toggleLeftRightInsertion"
-            name="Toggle left/right insertion in base call sequence">
-      </command>
       <command
             defaultHandler="eu.etaxonomy.taxeditor.editor.handler.OpenTaxonEditorHandler"
             id="eu.etaxonomy.taxeditor.editor.openTaxonEditor"
             id="eu.etaxonomy.taxeditor.description.commands.moveDescriptionElements"
             name="%command.name.12">
       </command>
-      <command
-            defaultHandler="eu.etaxonomy.taxeditor.editor.handler.EditSequenceHandler"
-            id="eu.etaxonomy.taxeditor.editor.editSequence"
-            name="Edit Sequence">
-      </command>
-      <command
-            defaultHandler="eu.etaxonomy.taxeditor.editor.handler.ShowPherogramHandler"
-            id="eu.etaxonomy.taxeditor.editor.showPherogram"
-            name="Show Pherogram">
-      </command>
    </extension>
    <extension
          point="org.eclipse.core.expressions.definitions">
             </test>
          </with>
       </definition>
-      <definition
-            id="isSequence">
-         <with
-               variable="selection">
-            <test
-                  property="eu.etaxonomy.taxeditor.editor.handler.SpecimenPropertyTester.isSequence">
-            </test>
-         </with>
-      </definition>
-      <definition
-            id="isSingleRead">
-         <with
-               variable="selection">
-            <test
-                  property="eu.etaxonomy.taxeditor.editor.handler.SpecimenPropertyTester.isSingleRead">
-            </test>
-         </with>
-      </definition>
    </extension>
    <extension
          point="org.eclipse.core.expressions.propertyTesters">
             properties="isGroupEditor"
             type="eu.etaxonomy.taxeditor.bulkeditor.BulkEditor">
       </propertyTester>
-      <propertyTester
-            class="eu.etaxonomy.taxeditor.editor.handler.SpecimenPropertyTester"
-            id="eu.etaxonomy.taxeditor.editor.handler.SpecimenPropertyTester"
-            namespace="eu.etaxonomy.taxeditor.editor.handler.SpecimenPropertyTester"
-            properties="isSequence,isSingleRead"
-            type="org.eclipse.jface.viewers.IStructuredSelection">
-      </propertyTester>
    </extension>
-   <extension
+    <extension
          point="org.eclipse.ui.bindings">   
       <scheme
             description="%scheme.description"
             id="eu.etaxonomy.taxeditor.bindings.scheme.default"
             name="%scheme.name">
       </scheme>
-      <key
-            commandId="eu.etaxonomy.taxeditor.editor.molecular.AlignmentEditor.loadPherogram"
-            schemeId="eu.etaxonomy.taxeditor.bindings.scheme.default"
-            sequence="M1+O">
-      </key>
    </extension>
     <extension
          point="org.eclipse.ui.importWizards">