Revision ef32cd3e
Added by Patrick Plitzner almost 7 years ago
eu.etaxonomy.taxeditor.application/fragment.e4xmi | ||
---|---|---|
36 | 36 |
<children xsi:type="menu:MenuSeparator" xmi:id="_zfx_cB7PEeeC-JvycL9ysA" elementId="eu.etaxonomy.taxeditor.application.windowMenu.last"/> |
37 | 37 |
<children xsi:type="menu:HandledMenuItem" xmi:id="_35iN8B7PEeeC-JvycL9ysA" elementId="org.eclipse.ui.main.menu.window.preferences" label="%command.label.12" command="_l9kXoB7PEeeC-JvycL9ysA"/> |
38 | 38 |
</children> |
39 |
<children xsi:type="menu:Menu" xmi:id="_KDFiMB6tEeePLJ5to5QrXQ" elementId="org.eclipse.ui.main.menu.admin" label="%menu.label.4"/> |
|
39 |
<children xsi:type="menu:Menu" xmi:id="_KDFiMB6tEeePLJ5to5QrXQ" elementId="org.eclipse.ui.main.menu.admin" label="%menu.label.4"> |
|
40 |
<children xsi:type="menu:HandledMenuItem" xmi:id="_RsV7EB-IEeeIA_2gwq7JKg" elementId="org.eclipse.ui.main.menu.admin.dbpreferences" label="%command.label.23" command="_JXXNIB-IEeeIA_2gwq7JKg"> |
|
41 |
<visibleWhen xsi:type="ui:CoreExpression" xmi:id="_ckfJUB-IEeeIA_2gwq7JKg" coreExpressionId="hasROLE_PROJECT_MANAGER_AND_isCdmStoreConnected"/> |
|
42 |
</children> |
|
43 |
<children xsi:type="menu:HandledMenuItem" xmi:id="_VgPDcB-IEeeIA_2gwq7JKg" elementId="org.eclipse.ui.main.menu.admin.dbrepair" label="%command.label.24" command="_LuEl0B-IEeeIA_2gwq7JKg"> |
|
44 |
<visibleWhen xsi:type="ui:CoreExpression" xmi:id="_06_ZIB-TEeeIA_2gwq7JKg" coreExpressionId="hasROLE_PROJECT_MANAGER_AND_isCdmStoreConnected"/> |
|
45 |
</children> |
|
46 |
</children> |
|
40 | 47 |
<children xsi:type="menu:Menu" xmi:id="_MG8QUB6tEeePLJ5to5QrXQ" elementId="org.eclipse.ui.main.menu.help" label="%menu.label.2"> |
41 | 48 |
<children xsi:type="menu:HandledMenuItem" xmi:id="_6vgg4B6gEeePLJ5to5QrXQ" elementId="id.commandlabel16" label="%command.label.16" command="_ye6jsB6gEeePLJ5to5QrXQ"/> |
42 | 49 |
<children xsi:type="menu:HandledMenuItem" xmi:id="_i-R80B6fEeePLJ5to5QrXQ" elementId="id.commandlabel20" label="%command.label.20" command="_V9LTcB6eEeePLJ5to5QrXQ"/> |
... | ... | |
46 | 53 |
<fragments xsi:type="fragment:StringModelFragment" xmi:id="_vvQmIB4JEeehWtOSgLepjA" featurename="handlers" parentElementId="org.eclipse.e4.legacy.ide.application"> |
47 | 54 |
<elements xsi:type="commands:Handler" xmi:id="_haDmcB6eEeePLJ5to5QrXQ" elementId="eu.etaxonomy.taxeditor.OpenExternalAboutPlatformHandler" contributionURI="bundleclass://eu.etaxonomy.taxeditor.application/eu.etaxonomy.taxeditor.OpenExternalAboutPlatformHandler" command="_V9LTcB6eEeePLJ5to5QrXQ"/> |
48 | 55 |
<elements xsi:type="commands:Handler" xmi:id="_3wxe4B6gEeePLJ5to5QrXQ" elementId="eu.etaxonomy.taxeditor.OpenExternalParserHelpHandler" contributionURI="bundleclass://eu.etaxonomy.taxeditor.application/eu.etaxonomy.taxeditor.OpenExternalParserHelpHandler" command="_ye6jsB6gEeePLJ5to5QrXQ"/> |
56 |
<elements xsi:type="commands:Handler" xmi:id="_cwy_oB-LEeeIA_2gwq7JKg" elementId="eu.etaxonomy.taxeditor.handler.OpenDatabaseRepairWizardHandler" contributionURI="bundleclass://eu.etaxonomy.taxeditor.store/eu.etaxonomy.taxeditor.handler.OpenDatabaseRepairWizardHandler" command="_LuEl0B-IEeeIA_2gwq7JKg"/> |
|
57 |
<elements xsi:type="commands:Handler" xmi:id="_pZ84gB-LEeeIA_2gwq7JKg" elementId="eu.etaxonomy.taxeditor.handler.OpenDatabasePreferencesWizardHandler" contributionURI="bundleclass://eu.etaxonomy.taxeditor.store/eu.etaxonomy.taxeditor.handler.OpenDatabasePreferencesWizardHandler" command="_JXXNIB-IEeeIA_2gwq7JKg"/> |
|
49 | 58 |
</fragments> |
50 | 59 |
<fragments xsi:type="fragment:StringModelFragment" xmi:id="_1jM6sB4JEeehWtOSgLepjA" featurename="commands" parentElementId="org.eclipse.e4.legacy.ide.application"> |
51 | 60 |
<elements xsi:type="commands:Command" xmi:id="_V9LTcB6eEeePLJ5to5QrXQ" elementId="eu.etaxonomy.taxeditor.application.help.aboutPlatform" commandName="%command.name.0"/> |
... | ... | |
65 | 74 |
<elements xsi:type="commands:Command" xmi:id="_WOTDYB7EEeeRW_RHu3JLqQ" elementId="org.eclipse.ui.edit.delete" commandName="%command.label.11"/> |
66 | 75 |
<elements xsi:type="commands:Command" xmi:id="_l9kXoB7PEeeC-JvycL9ysA" elementId="org.eclipse.ui.window.preferences" commandName="%command.label.12"/> |
67 | 76 |
<elements xsi:type="commands:Command" xmi:id="_hooiQB7QEeeC-JvycL9ysA" elementId="org.eclipse.ui.newWizard" commandName="%command.label.21"/> |
77 |
<elements xsi:type="commands:Command" xmi:id="_JXXNIB-IEeeIA_2gwq7JKg" elementId="eu.etaxonomy.taxeditor.application.DatabaseSettings" commandName="%command.label.23"/> |
|
78 |
<elements xsi:type="commands:Command" xmi:id="_LuEl0B-IEeeIA_2gwq7JKg" elementId="eu.etaxonomy.taxeditor.application.DatabaseRepairFunctionality" commandName="%command.label.24"/> |
|
68 | 79 |
</fragments> |
69 | 80 |
</fragment:ModelFragments> |
eu.etaxonomy.taxeditor.application/plugin.xml | ||
---|---|---|
65 | 65 |
<menuContribution |
66 | 66 |
allPopups="false" |
67 | 67 |
locationURI="menu:org.eclipse.ui.main.menu.admin"> |
68 |
<command |
|
69 |
commandId="eu.etaxonomy.taxeditor.application.DatabaseSettings" |
|
70 |
label="%command.label.23" |
|
71 |
style="push"> |
|
72 |
<visibleWhen |
|
73 |
checkEnabled="true"> |
|
74 |
<and> |
|
75 |
<reference |
|
76 |
definitionId="hasROLE_PROJECT_MANAGER"> |
|
77 |
</reference> |
|
78 |
<reference |
|
79 |
definitionId="isCdmStoreConnected"> |
|
80 |
</reference> |
|
81 |
</and> |
|
82 |
</visibleWhen> |
|
83 |
</command> |
|
84 |
<command |
|
85 |
commandId="eu.etaxonomy.taxeditor.application.DatabaseRepairFunctionality" |
|
86 |
label="%command.label.24" |
|
87 |
style="push"> |
|
88 |
<visibleWhen |
|
89 |
checkEnabled="true"> |
|
90 |
<and> |
|
91 |
<reference |
|
92 |
definitionId="hasROLE_PROJECT_MANAGER"> |
|
93 |
</reference> |
|
94 |
<reference |
|
95 |
definitionId="isCdmStoreConnected"> |
|
96 |
</reference> |
|
97 |
</and> |
|
98 |
</visibleWhen> |
|
99 |
</command> |
|
100 | 68 |
<dynamic |
101 | 69 |
class="eu.etaxonomy.taxeditor.admin.UserGroupContributionItem" |
102 | 70 |
id="eu.etaxonomy.taxeditor.admin.UserGroupContributionItem"> |
... | ... | |
151 | 119 |
commandId="org.eclipse.ui.help.aboutAction" |
152 | 120 |
label="%command.label.19"> |
153 | 121 |
</command> |
154 |
</menuContribution> |
|
155 |
<menuContribution |
|
156 |
locationURI="toolbar:org.eclipse.ui.main.toolbar"> |
|
157 |
<toolbar |
|
158 |
id="eu.etaxonomy.taxeditor.editor.main"> |
|
159 |
<command |
|
160 |
commandId="org.eclipse.ui.newWizard" |
|
161 |
label="%command.label.21" |
|
162 |
style="push"> |
|
163 |
</command> |
|
164 |
<command |
|
165 |
commandId="org.eclipse.ui.file.save" |
|
166 |
label="%command.label.22" |
|
167 |
style="push"> |
|
168 |
</command> |
|
169 |
</toolbar> |
|
170 | 122 |
</menuContribution> |
171 | 123 |
</extension> |
172 | 124 |
<extension |
eu.etaxonomy.taxeditor.store/META-INF/MANIFEST.MF | ||
---|---|---|
70 | 70 |
org.eclipse.core.databinding.beans, |
71 | 71 |
org.eclipse.core.databinding.observable, |
72 | 72 |
org.eclipse.core.databinding.property, |
73 |
org.eclipse.jface.databinding |
|
73 |
org.eclipse.jface.databinding, |
|
74 |
org.eclipse.e4.core.di.annotations;bundle-version="1.5.0" |
|
74 | 75 |
Import-Package: eu.etaxonomy.taxeditor.webapp, |
75 | 76 |
org.eclipse.core.commands, |
76 | 77 |
org.eclipse.core.commands.operations, |
eu.etaxonomy.taxeditor.store/plugin.xml | ||
---|---|---|
817 | 817 |
typeId="eu.etaxonomy.taxeditor.uuidParameterType"> |
818 | 818 |
</commandParameter> |
819 | 819 |
</command> |
820 |
<command |
|
821 |
defaultHandler="eu.etaxonomy.taxeditor.handler.OpenDatabasePreferencesWizardHandler" |
|
822 |
id="eu.etaxonomy.taxeditor.application.DatabaseSettings" |
|
823 |
name="%command.label.23"> |
|
824 |
</command> |
|
825 |
<command |
|
826 |
defaultHandler="eu.etaxonomy.taxeditor.handler.OpenDatabaseRepairWizardHandler" |
|
827 |
id="eu.etaxonomy.taxeditor.application.DatabaseRepairFunctionality" |
|
828 |
name="%command.label.24"> |
|
829 |
</command> |
|
830 | 820 |
</extension> |
831 | 821 |
<extension |
832 | 822 |
point="org.eclipse.ui.commands"> |
... | ... | |
1376 | 1366 |
</iterate> |
1377 | 1367 |
</with> |
1378 | 1368 |
</definition> |
1369 |
<definition |
|
1370 |
id="hasROLE_PROJECT_MANAGER_AND_isCdmStoreConnected"> |
|
1371 |
<and> |
|
1372 |
<reference |
|
1373 |
definitionId="hasROLE_PROJECT_MANAGER"> |
|
1374 |
</reference> |
|
1375 |
<reference |
|
1376 |
definitionId="isCdmStoreConnected"> |
|
1377 |
</reference> |
|
1378 |
</and> |
|
1379 |
</definition> |
|
1379 | 1380 |
</extension> |
1380 | 1381 |
<extension |
1381 | 1382 |
point="org.eclipse.ui.activities"> |
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/OpenDatabasePreferencesWizardHandler.java | ||
---|---|---|
8 | 8 |
*/ |
9 | 9 |
package eu.etaxonomy.taxeditor.handler; |
10 | 10 |
|
11 |
import org.eclipse.core.commands.AbstractHandler; |
|
12 |
import org.eclipse.core.commands.ExecutionEvent; |
|
13 |
import org.eclipse.core.commands.ExecutionException; |
|
11 |
import org.eclipse.e4.core.di.annotations.Execute; |
|
14 | 12 |
import org.eclipse.jface.wizard.WizardDialog; |
15 | 13 |
|
16 | 14 |
import eu.etaxonomy.taxeditor.databaseAdmin.wizard.DatabasePreferencesWizard; |
17 |
import eu.etaxonomy.taxeditor.store.StoreUtil;
|
|
15 |
import eu.etaxonomy.taxeditor.model.AbstractUtility;
|
|
18 | 16 |
|
19 | 17 |
/** |
20 | 18 |
* @author k.luther |
21 | 19 |
* @date 18.11.2016 |
22 | 20 |
* |
23 | 21 |
*/ |
24 |
public class OpenDatabasePreferencesWizardHandler extends AbstractHandler{
|
|
22 |
public class OpenDatabasePreferencesWizardHandler { |
|
25 | 23 |
|
26 |
String commandID = "eu.etaxonomy.taxeditor.store.open.OpenDatabasePreferencesWizardHandler"; |
|
27 |
|
|
28 |
@Override |
|
29 |
public Object execute(ExecutionEvent event) throws ExecutionException { |
|
24 |
@Execute |
|
25 |
public Object execute(){ |
|
30 | 26 |
DatabasePreferencesWizard databasePreferencesWizard = new DatabasePreferencesWizard(); |
31 |
WizardDialog dialog = new WizardDialog(StoreUtil.getShell(),
|
|
27 |
WizardDialog dialog = new WizardDialog(AbstractUtility.getShell(),
|
|
32 | 28 |
databasePreferencesWizard); |
33 | 29 |
|
34 | 30 |
dialog.open(); |
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/OpenDatabaseRepairWizardHandler.java | ||
---|---|---|
8 | 8 |
*/ |
9 | 9 |
package eu.etaxonomy.taxeditor.handler; |
10 | 10 |
|
11 |
import org.eclipse.core.commands.AbstractHandler; |
|
12 |
import org.eclipse.core.commands.ExecutionEvent; |
|
13 |
import org.eclipse.core.commands.ExecutionException; |
|
11 |
import org.eclipse.e4.core.di.annotations.Execute; |
|
14 | 12 |
import org.eclipse.jface.wizard.WizardDialog; |
15 | 13 |
|
16 | 14 |
import eu.etaxonomy.taxeditor.databaseAdmin.wizard.DatabaseRepairWizard; |
17 |
import eu.etaxonomy.taxeditor.store.StoreUtil;
|
|
15 |
import eu.etaxonomy.taxeditor.model.AbstractUtility;
|
|
18 | 16 |
|
19 | 17 |
|
20 | 18 |
|
... | ... | |
23 | 21 |
* @date 06.12.2016 |
24 | 22 |
* |
25 | 23 |
*/ |
26 |
public class OpenDatabaseRepairWizardHandler extends AbstractHandler {
|
|
24 |
public class OpenDatabaseRepairWizardHandler{ |
|
27 | 25 |
|
28 | 26 |
/** |
29 | 27 |
* {@inheritDoc} |
30 | 28 |
*/ |
31 |
@Override
|
|
32 |
public Object execute(ExecutionEvent event) throws ExecutionException {
|
|
29 |
@Execute
|
|
30 |
public Object execute(){
|
|
33 | 31 |
DatabaseRepairWizard databaseRepairWizard = new DatabaseRepairWizard(); |
34 |
WizardDialog dialog = new WizardDialog(StoreUtil.getShell(),
|
|
32 |
WizardDialog dialog = new WizardDialog(AbstractUtility.getShell(),
|
|
35 | 33 |
databaseRepairWizard); |
36 | 34 |
|
37 | 35 |
dialog.open(); |
Also available in: Unified diff
ref #6566 Migrate org.eclipse.ui.main.menu.admin DB items