- removed accidentally commited LibrAlign code
[taxeditor.git] / eu.etaxonomy.taxeditor.store / plugin.xml
index c9b01ec7cb767f832dc39292c3e929609c19a22a..8277d0a748a1687f61e98b262339412ef4c278f8 100644 (file)
                label="Switch User"
                style="push">
          </command>
+         <command
+               commandId="eu.etaxonomy.taxeditor.store.openPasswordWizzard"
+               label="Change Password"
+               style="push">
+         </command>
          <separator
                name="eu.etaxonomy.taxeditor.application.filemenu.login"
                visible="true">
                commandId="eu.etaxonomy.taxeditor.store.datasource.change"
                label="Connect"
                style="push">
+               <visibleWhen>
+              <with
+                        variable="selection">
+                        <not>
+                               <test
+                                       property="eu.etaxonomy.taxeditor.datasource.propertyTester.test">
+                               </test>
+                       </not>
+                       </with>
+            </visibleWhen>
          </command>
          <command
                commandId="eu.etaxonomy.taxeditor.store.datasource.create"
                commandId="eu.etaxonomy.taxeditor.store.datasource.edit"
                label="Edit"
                style="push">
+                <visibleWhen>
+              <with
+                        variable="selection">
+                        <not>
+                               <test
+                                       property="eu.etaxonomy.taxeditor.datasource.propertyTester.test">
+                               </test>
+                       </not>
+                       </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="eu.etaxonomy.taxeditor.store.datasource.clone"
+               label="Clone"
+               style="push">
+                <visibleWhen>
+              <with
+                        variable="selection">
+                        <not>
+                               <test
+                                       property="eu.etaxonomy.taxeditor.datasource.propertyTester.test">
+                               </test>
+                       </not>
+                       </with>
+            </visibleWhen>
          </command>
          <separator
                name="eu.etaxonomy.taxeditor.store.datasource.separator"
                commandId="org.eclipse.ui.edit.delete"
                label="Delete"
                style="push">
+               <visibleWhen>
+              <with
+                        variable="selection">
+                        <not>
+                               <test
+                                       property="eu.etaxonomy.taxeditor.datasource.propertyTester.test">
+                               </test>
+                       </not>
+                       </with>
+            </visibleWhen>
          </command>
          <separator
                name="eu.etaxonomy.taxeditor.store.datasource.separator2"
                commandId="eu.etaxonomy.taxeditor.store.datasource.close"
                label="Close Active Connection"
                style="push">
+               <visibleWhen>
+              <with
+                        variable="selection">
+                        <not>
+                               <test
+                                       property="eu.etaxonomy.taxeditor.datasource.propertyTester.test">
+                               </test>
+                       </not>
+                       </with>
+            </visibleWhen>
          </command>
          <command
                commandId="eu.etaxonomy.taxeditor.store.datasource.update"
                   </reference>
                </not>
             </visibleWhen>
+            
          </command>
       </menuContribution>
       <menuContribution
             </with>
          </activeWhen>
       </handler>
+      <handler
+            class="eu.etaxonomy.taxeditor.featuretree.OpenFeatureTreeEditorWizardHandler"
+            commandId="eu.etaxonomy.taxeditor.store.open.FeatureTreeEditorWizard">
+         <activeWhen>
+            <reference
+                  definitionId="hasROLE_PROJECT_MANAGER">
+            </reference>
+         </activeWhen>
+      </handler>
+      <handler
+            class="eu.etaxonomy.taxeditor.handler.ShowLoginWindowHandler"
+            commandId="eu.etaxonomy.taxeditor.store.operations.showLoginWindow">
+         <enabledWhen>
+            <reference
+                  definitionId="isUserLoggedIn">
+            </reference></enabledWhen>
+      </handler>
+      <handler
+            class="eu.etaxonomy.taxeditor.handler.OpenPasswordWizzardHandler"
+            commandId="eu.etaxonomy.taxeditor.store.openPasswordWizzard">
+         <enabledWhen>
+            <reference
+                  definitionId="isUserLoggedIn">
+            </reference></enabledWhen>
+      </handler>
+   </extension>
+   <extension
+         point="org.eclipse.ui.commands">
+      <command
+            defaultHandler="eu.etaxonomy.taxeditor.view.datasource.handler.ChangeConnectionHandler"
+            id="eu.etaxonomy.taxeditor.datasource.connect"
+            name="Connect">
+      </command>
    </extension>
    <extension
          name="Popup Menu Commands"
             id="eu.etaxonomy.taxeditor.store.datasource.edit"
             name="Edit Datasource">
       </command>
+      <command
+            defaultHandler="eu.etaxonomy.taxeditor.view.datasource.handler.CloneDataSourceHandler"
+            id="eu.etaxonomy.taxeditor.store.datasource.clone"
+            name="Clone Datasource">
+      </command>
       <command
             defaultHandler="eu.etaxonomy.taxeditor.view.datasource.handler.CreateDataSourceHandler"
             id="eu.etaxonomy.taxeditor.store.datasource.create"
             name="Update Datasource">
       </command>
       <command
-            defaultHandler="eu.etaxonomy.taxeditor.handler.ShowLoginWindowHandler"
             id="eu.etaxonomy.taxeditor.store.operations.showLoginWindow"
             name="Show Login Window">
       </command>
             defaultHandler="eu.etaxonomy.taxeditor.editor.definedterm.handler.OpenDefinedTermEditorHandler"
             id="eu.etaxonomy.taxeditor.store.openDefinedTermEditor"
             name="Open Defined Term Editor">
-         <commandParameter
-               id="eu.etaxonomy.taxeditor.store.openDefinedTermEditor.termTypeClass"
-               name="inputType"
-               optional="true">
-         </commandParameter>
          <commandParameter
                id="eu.etaxonomy.taxeditor.store.openDefinedTermEditor.termTypeUuid"
                name="inputType"
             id="eu.etaxonomy.taxeditor.editor.definedTerms.newTermVocabulary"
             name="New Term Vocabulary">
       </command>
+      <command
+         id="eu.etaxonomy.taxeditor.store.open.FeatureTreeEditorWizard"
+         name="Open Feature Tree Editor Wizard">
+         </command>
+      <command
+            id="eu.etaxonomy.taxeditor.store.openPasswordWizzard"
+            name="Open Password Wizzard">
+      </command>
    </extension>
    <extension
          point="org.eclipse.ui.importWizards">
             id="eu.etaxonomy.taxeditor.io.import.tcs"
             name="TCS">
       </wizard>
-<!--      <wizard
+   <!--   <wizard
             category="eu.etaxonomy.taxeditor.import.category.cdm"
             class="eu.etaxonomy.taxeditor.io.wizard.JaxbImportWizard"
             id="eu.etaxonomy.taxeditor.io.import.jaxb"
             name="JAXB">
       </wizard> -->
-      <wizard
+   <!--   <wizard
             category="eu.etaxonomy.taxeditor.import.category.cdm"
             class="eu.etaxonomy.taxeditor.io.wizard.BerlinModelImportWizard"
             id="eu.etaxonomy.taxeditor.io.import.berlinModel"
             class="eu.etaxonomy.taxeditor.io.wizard.EndnoteImportWizard"
             id="eu.etaxonomy.taxeditor.io.import.endnote"
             name="Endnote">
-      </wizard>
+      </wizard>-->
       <wizard
             category="eu.etaxonomy.taxeditor.import.category.cdm"
             class="eu.etaxonomy.taxeditor.io.wizard.ExcelNormalExplicitTaxaImportWizard"
             id="eu.etaxonomy.taxeditor.io.export.jaxb"
             name="JAXB">
       </wizard>
-      <wizard
+      <!--<wizard
             category="eu.etaxonomy.taxeditor.export.category.cdm"
             class="eu.etaxonomy.taxeditor.io.wizard.BerlinModelExportWizard"
             id="eu.etaxonomy.taxeditor.io.export.berlinModel"
             name="Berlin Model">
-      </wizard>
+      </wizard>-->
       <category
             id="eu.etaxonomy.taxeditor.export.category.excel"
             name="Excel">
          namespace="eu.etaxonomy.taxeditor.datasource.propertyTester"
          properties="isCompatible"
          type="org.eclipse.jface.viewers.IStructuredSelection">
+   </propertyTester>
+    <propertyTester
+         class="eu.etaxonomy.taxeditor.view.datasource.handler.DataSourceMenuPropertyTester"
+         id="eu.etaxonomy.taxeditor.datasource.propertyTester"
+         namespace="eu.etaxonomy.taxeditor.datasource.propertyTester"
+         properties="test"
+         type="org.eclipse.jface.viewers.IStructuredSelection">
    </propertyTester>
    <propertyTester
          class="eu.etaxonomy.taxeditor.preference.PreferencePropertyTester"
             </test>
          </with>
       </definition>
+      <definition
+            id="isUserLoggedIn">
+            <with
+               variable="eu.etaxonomy.taxeditor.security.user">
+               <instanceof
+                     value="eu.etaxonomy.cdm.model.common.User">
+               </instanceof>
+         </with>
+      </definition>
       <definition
             id="hasROLE_USER_MANAGER">
             <with
 <extension
       point="org.eclipse.ui.services">
    <sourceProvider
-         provider="eu.etaxonomy.taxeditor.security.RolesSourceProvider">
+         provider="eu.etaxonomy.taxeditor.security.AuthenticationSourceProvider">
       <variable
             name="eu.etaxonomy.taxeditor.security.userRoles"
             priorityLevel="workbench">
       </variable>
    </sourceProvider>
 </extension>
-       
 </plugin>