Project

General

Profile

« Previous | Next » 

Revision dcec2a45

Added by Katja Luther almost 9 years ago

#4855 add MoveSynonymToAnotherAcceptedTaxonHandler and some clean up of the plugin.xml especially the delete

View differences:

.gitattributes
355 355
eu.etaxonomy.taxeditor.editor/META-INF/MANIFEST.MF -text
356 356
eu.etaxonomy.taxeditor.editor/OSGI-INF/l10n/plugin.properties -text
357 357
eu.etaxonomy.taxeditor.editor/OSGI-INF/l10n/plugin_de.properties -text
358
eu.etaxonomy.taxeditor.editor/OSGI-INF/l10n/plugin_en.properties -text
358 359
eu.etaxonomy.taxeditor.editor/build.properties -text
359 360
eu.etaxonomy.taxeditor.editor/icons/address-book-new.png -text
360 361
eu.etaxonomy.taxeditor.editor/icons/camera-photo.png -text
......
460 461
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/DeleteAllEmptyNamesHandler.java -text
461 462
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/DeleteTaxonBaseHandler.java -text
462 463
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/GroupBasionymContributionItem.java -text
464
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/MoveSynonymToAnotherAcceptedTaxonHandler.java -text
463 465
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/NameEditorMenuPropertyTester.java -text
464 466
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/RemoveBasionymHandler.java -text
465 467
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/SetBasionymHandler.java -text
eu.etaxonomy.taxeditor.editor/OSGI-INF/l10n/plugin.properties
153 153
command.name.43 = Create Field Unit
154 154
command.name.44 = Deep Delete
155 155
command.name.46 = Move Synonym (Homotypical Group) to another Accepted Taxon
156
command.label.56 = Move Synonym (Homotypical Group) to another Accepted Taxon
156
command.label.56 = Move Synonym (Homotypical Group) to another Accepted Taxon
157
markerContentGenerator.name = Validation Problems Marker Generator
158
command.name.45 = Delete
159
command.name.47 = Delete
160
commandParameter.name = taxonUUID
161
Bundle-Name = Editor Bundle
162
command.name.48 = delete
163
command.name.49 = delete
164
command.name.50 = delete
eu.etaxonomy.taxeditor.editor/OSGI-INF/l10n/plugin_en.properties
1
#Properties file for taxeditor-editor
2
Bundle-Vendor.0 = EDIT
3
Bundle-Name.0 = EDIT Taxonomic Editor - Editor Bundle
4
command.name.17 = Set Basionym
5
command.name.18 = Remove Basionym
6
editor.name = Multipage Taxon Editor
7
editor.name.0 = Taxon Name Editor
8
editor.name.1 = Key
9
editor.name.2 = Polytomous Key Graph Editor
10
editor.name.3 = Polytomous Key List Editor
11
editor.name.4 = Cdm Authority Editor
12
editor.name.5 = Derivate View
13
view.name = Factual Data
14
view.name.0 = Uses
15
view.name.1 = Media
16
view.name.2 = Concept Relations
17
view.name.3 = Concept Graph
18
category.name = Taxonomic Editor
19
command.label = Reference
20
command.label.0 = Name
21
command.label.1 = Team
22
command.label.2 = Person
23
command.label.3 = Specimen
24
command.label.4 = Factual Data
25
command.label.5 = Media
26
command.label.6 = Concept
27
command.label.7 = Concept Graph
28
command.label.8 = Open Parent
29
menu.label = New
30
command.label.9 = Heterotypic Synonym
31
command.label.10 = Homotypic Synonym
32
command.label.11 = Synonym In Homotypical Group
33
menu.label.0 = Change To
34
command.label.12 = Accepted Taxon
35
command.label.13 = Synonym
36
command.label.14 = Misapplication
37
command.label.15 = Delete
38
command.label.16 = Delete All Empty Names
39
command.label.17 = Swap Synonym With Accepted
40
command.label.18 = Show Details
41
command.label.19 = Save
42
command.label.20 = New Node
43
command.label.21 = Delete
44
command.label.22 = Apply Layout
45
command.label.23 = New Key Number
46
command.label.24 = New Alternative
47
command.label.25 = Refresh Nodes
48
command.label.26 = Delete
49
command.label.27 = New Factual Data
50
menu.label.1 = New
51
command.label.28 = Move Description to Taxon
52
command.label.29 = Move Elements to Taxon
53
command.label.30 = Delete
54
command.label.31 = Save
55
menu.label.2 = New Derivate
56
command.label.32 = New Use
57
command.label.33 = New Use Summary
58
command.label.34 = New Use Record
59
command.label.35 = Delete
60
command.label.36 = Save
61
command.label.37 = New Image Gallery
62
command.label.38 = New Image
63
command.label.39 = Move Image Up In List
64
command.label.40 = Move Image Down In List
65
command.label.41 = Delete
66
command.label.42 = Save
67
menu.label.3 = New
68
command.label.43 = Open Related Concept
69
command.label.44 = Delete
70
command.label.45 = Edit Authorities
71
extension.name = Name Commands
72
category.name.0 = -- Name Editor
73
command.name = Open Parent
74
command.name.0 = Create Homotypic Synonym
75
command.name.1 = Create Heterotypic Synonym
76
command.name.2 = Create Synonym In Homotypical Group
77
command.name.3 = Change To Synonym
78
command.name.4 = Change To Accepted Taxon
79
command.name.5 = Change To Misapplication
80
command.name.6 = Swap Synonym With Accepted
81
command.name.7 = Set Basionym / Original Combination
82
command.name.8 = Remove Basionym / Original Combination
83
command.name.9 = Delete All Empty Names
84
category.name.1 = -- Factual
85
command.name.10 = Create Description Element
86
command.name.11 = New Description
87
command.name.12 = Move Description Elements to Taxon
88
command.name.13 = Move Description to Taxon
89
category.name.2 = -- New Uses
90
command.name.14 = New Use
91
command.name.15 = New Use Summary
92
command.name.16 = New Use Record
93
category.name.3 = -- Media
94
command.name.19 = Move Image Down In List
95
command.name.20 = New Image Gallery
96
command.name.21 = New Image
97
command.name.22 = Move Image Up In List
98
category.name.4 = -- New Entity
99
command.name.23 = New Reference
100
command.name.24 = New Name
101
command.name.25 = New Team
102
command.name.26 = New Person
103
command.name.27 = New Specimen
104
category.name.5 = -- Polytomous Keys
105
command.name.28 = New Child Node
106
command.name.29 = New Sibling Node
107
command.name.30 = Refresh Node Numbering
108
command.name.31 = Apply Layout
109
category.name.6 = -- Concept Relations
110
command.name.32 = Create Concept Relation
111
command.name.33 = Open Related Concept
112
category.name.7 = -- Group
113
command.name.34 = Edit CDM Authorities
114
command.name.35 = Open Derivate View
115
scheme.description = The default key binding scheme for the Taxonomic Editor
116
scheme.name = Taxonomic Editor Default Key Bindingseditor.name.6 = Specimen Import Editor
117
editor.name.7 = Gbif Import Editor
118
editor.name.8 = Checklist Editor
119
view.name.4 = Specimen Import
120
view.name.5 = GBIF Specimen Import
121
command.label.46 = Name
122
command.label.47 = Reference
123
command.label.48 = Datasource
124
command.label.49 = Misapplication
125
command.label.50 = Use Existing Image
126
command.name.36 = Create Misapplication
127
command.name.37 = Use Existing Image
128
command.name.38 = Open Checklist Editor
129
command.name.39 = New Datasource
130
wizard.name = Specimen Search/Import
131
wizard.description = Queries data provider for specimens with specified parameters.\nNote: Query results are currently limited to 100.
132
command.name.40 = Validation
133
view.name.6 = Validation
134
marker.field.0 = Object Type
135
marker.field.1 = Object
136
marker.field.2 = Attribute
137
marker.field.3 = Problematic Value
138
marker.field.4 = Problem description
139
marker.field.5 = Validator
140
marker.field.6 = Entity Class
141
marker.field.7 = Entity Id
eu.etaxonomy.taxeditor.editor/plugin.xml
172 172
	<extension point="org.eclipse.ui.ide.markerSupport">
173 173
	    <markerContentGenerator
174 174
		    id="eu.etaxonomy.taxeditor.editor.validation.ValidationProblemsMarkerGenerator" 
175
		    name="Validation Problems Marker Generator">  
175
		    name="%markerContentGenerator.name">  
176 176
	    	<markerTypeReference id="eu.etaxonomy.taxeditor.markers.validationerror" />
177 177
	    	
178 178
	    	<markerFieldReference id="eu.etaxonomy.taxeditor.markers.validation.userFriendlyTypeName" visible="true" />
......
468 468
               visible="true">
469 469
         </separator>
470 470
         <command
471
               commandId="org.eclipse.ui.edit.delete"
471
               commandId="eu.etaxonomy.taxeditor.editor.name.delete"
472 472
               label="%command.label.15"
473 473
               style="push">
474 474
            <visibleWhen>
......
568 568
               visible="true">
569 569
         </separator>
570 570
         <command
571
               commandId="org.eclipse.ui.edit.delete"
571
               commandId="eu.etaxonomy.taxeditor.key.polytomous.delete"
572 572
               label="%command.label.21"
573 573
               style="push">
574 574
         </command>
......
604 604
               style="push">
605 605
         </command>
606 606
         <command
607
               commandId="org.eclipse.ui.edit.delete"
607
               commandId="eu.etaxonomy.taxeditor.key.polytomous.command.delete"
608 608
               label="%command.label.26"
609 609
               style="push">
610 610
         </command>
......
612 612
      <menuContribution
613 613
            locationURI="popup:eu.etaxonomy.taxeditor.editor.view.descriptive">
614 614
         <command
615
               commandId="eu.etaxonomy.taxeditor.description.commands.adddescription"
615
               commandId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.adddescription"
616 616
               label="%command.label.27"
617 617
               style="push">
618 618
         </command>
......
665 665
            </visibleWhen>
666 666
         </command>
667 667
         <command
668
               commandId="eu.etaxonomy.taxeditor.editor.commands.description.moveDescriptionToTaxon"
668
               commandId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.moveDescriptionToTaxon"
669 669
               label="%command.label.28"
670 670
               style="push">
671 671
            <visibleWhen
......
676 676
            </visibleWhen>
677 677
         </command>
678 678
         <command
679
               commandId="eu.etaxonomy.taxeditor.description.commands.moveDescriptionElements"
679
               commandId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.moveDescriptionElements"
680 680
               label="%command.label.29"
681 681
               style="push">
682 682
            <visibleWhen
......
695 695
               name="eu.etaxonomy.taxeditor.taxonDescriptionEditor.separator.afterNew"
696 696
               visible="true">
697 697
         </separator>
698
         <command
699
               commandId="org.eclipse.ui.edit.delete"
698
                  <command
699
               commandId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.delete"
700 700
               label="%command.label.30"
701 701
               style="push">
702 702
         </command>
......
716 716
      <menuContribution
717 717
            locationURI="popup:eu.etaxonomy.taxeditor.editor.view.derivate.DerivateView">
718 718
         <command
719
               commandId="org.eclipse.ui.edit.delete"
719
               commandId="eu.etaxonomy.taxeditor.editor.derivate.delete"
720 720
               label="%command.label.52"
721 721
               style="push">
722 722
         </command>
......
812 812
               visible="true">
813 813
         </separator>
814 814
         <command
815
               commandId="org.eclipse.ui.edit.delete"
815
               commandId="eu.etaxonomy.taxeditor.editor.use.command.delete"
816 816
               label="%command.label.35"
817 817
               style="push">
818 818
         </command>
......
834 834
      <menuContribution
835 835
            locationURI="popup:eu.etaxonomy.taxeditor.editor.view.media">
836 836
         <command
837
               commandId="taxeditor-editor.command.newimagegallery"
837
               commandId="eu.etaxonomy.taxeditor.editor.media.command.newimagegallery"
838 838
               label="%command.label.37"
839 839
               style="push">
840 840
            <visibleWhen>
......
856 856
               visible="true">
857 857
         </separator>
858 858
         <command
859
               commandId="taxeditor-editor.newimage"
859
               commandId="eu.etaxonomy.taxeditor.editor.media.command.newimage"
860 860
               label="%command.label.38"
861 861
               style="push">
862 862
            <visibleWhen>
......
866 866
            </visibleWhen>
867 867
         </command>
868 868
         <command
869
               commandId="taxeditor-editor.useExistingImage"
869
               commandId="eu.etaxonomy.taxeditor.editor.media.command.useExistingImage"
870 870
               label="%command.label.50"
871 871
               style="push">
872 872
            <visibleWhen>
......
876 876
            </visibleWhen>
877 877
         </command>
878 878
         <command
879
               commandId="taxeditor-editor.command.moveimgdown"
879
               commandId="eu.etaxonomy.taxeditor.editor.media.command.moveimgdown"
880 880
               label="%command.label.39"
881 881
               style="push">
882 882
            <visibleWhen>
......
886 886
            </visibleWhen>
887 887
         </command>
888 888
         <command
889
               commandId="taxeditor-editor.command.moveimgup"
889
               commandId="eu.etaxonomy.taxeditor.editor.media.command.moveimgup"
890 890
               label="%command.label.40"
891 891
               style="push">
892 892
            <visibleWhen>
......
900 900
               visible="true">
901 901
         </separator>
902 902
         <command
903
               commandId="org.eclipse.ui.edit.delete"
903
               commandId="eu.etaxonomy.taxeditor.editor.media.command.delete"
904 904
               label="%command.label.41"
905 905
               style="push">
906 906
         </command>
......
929 929
               visible="true">
930 930
         </separator>
931 931
         <command
932
               commandId="org.eclipse.ui.edit.delete"
932
               commandId="eu.etaxonomy.taxeditor.editor.view.concept.command.delete"
933 933
               label="%command.label.44"
934 934
               style="push">
935 935
         </command>
......
1019 1019
      </handler>
1020 1020
      <handler
1021 1021
            class="eu.etaxonomy.taxeditor.editor.name.handler.DeleteTaxonBaseHandler"
1022
            commandId="org.eclipse.ui.edit.delete">
1022
            commandId="eu.etaxonomy.taxeditor.editor.name.command.delete">
1023 1023
         <activeWhen>
1024 1024
            <and>
1025 1025
               <reference
......
1035 1035
      </handler>
1036 1036
      <handler
1037 1037
            class="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.DeleteHandler"
1038
            commandId="org.eclipse.ui.edit.delete">
1038
            commandId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.delete">
1039 1039
          <activeWhen>
1040 1040
             <with
1041 1041
                   variable="activePartId">
......
1046 1046
                   <equals
1047 1047
                         value="eu.etaxonomy.taxeditor.editor.view.media">
1048 1048
                   </equals>
1049
                   <equals
1050
                     	value="eu.etaxonomy.taxeditor.editor.view.uses">
1051
               		</equals>
1049 1052
                </or>
1050
             </with>
1051
          </activeWhen>
1053
           	 </with>
1054
         </activeWhen>
1052 1055
      </handler>
1053 1056
      <handler
1054 1057
            class="eu.etaxonomy.taxeditor.editor.key.polytomous.handler.DeleteNodeHandler"
1055
            commandId="org.eclipse.ui.edit.delete">
1058
            commandId="eu.etaxonomy.taxeditor.editor.key.polytomous.command.delete">
1056 1059
         <activeWhen>
1057 1060
            <with
1058 1061
                  variable="activePartId">
......
1064 1067
      </handler>
1065 1068
      <handler
1066 1069
            class="eu.etaxonomy.taxeditor.editor.view.concept.handler.DeleteConceptRelationHandler"
1067
            commandId="org.eclipse.ui.edit.delete">
1070
            commandId="eu.etaxonomy.taxeditor.editor.view.concept.command.delete">
1068 1071
         <activeWhen>
1069 1072
            <with
1070 1073
                  variable="activePartId">
......
1074 1077
            </with>
1075 1078
         </activeWhen>
1076 1079
      </handler>
1077
      <handler
1078
            class="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.DeleteHandler"
1079
            commandId="org.eclipse.ui.edit.delete">
1080
         <activeWhen>
1081
            <with
1082
                  variable="activePartId">
1083
               <equals
1084
                     value="eu.etaxonomy.taxeditor.editor.view.uses">
1085
               </equals>
1086
            </with>
1087
         </activeWhen>
1088
      </handler>
1089 1080
      <handler
1090 1081
            class="eu.etaxonomy.taxeditor.editor.handler.OpenChecklistEditorHandler"
1091 1082
            commandId="eu.etaxonomy.taxeditor.editor.handler.OpenChecklistEditorHandler">
1092 1083
      </handler>
1093 1084
      <handler
1094 1085
            class="eu.etaxonomy.taxeditor.editor.view.derivate.handler.DeleteDerivateHandler"
1095
            commandId="org.eclipse.ui.edit.delete">
1086
            commandId="eu.etaxonomy.taxeditor.editor.view.derivate.command.delete">
1096 1087
         <activeWhen>
1097 1088
            <with
1098 1089
                  variable="activePartId">
......
1185 1176
            id="eu.etaxonomy.taxeditor.editor.name.swapSynonymAndAccepted"
1186 1177
            name="%command.name.6">
1187 1178
      </command>
1188
       <command
1179
      <command
1189 1180
            categoryId="eu.etaxonomy.taxeditor.editor.taxon.name.command.category"
1190 1181
            defaultHandler="eu.etaxonomy.taxeditor.editor.name.handler.MoveSynonymToAnotherAcceptedTaxonHandler"
1191 1182
            id="eu.etaxonomy.taxeditor.editor.name.moveSynonymToAnotherAcceptedTaxon"
......
1209 1200
            id="eu.etaxonomy.taxeditor.editor.name.changeAcceptedToSynonym"
1210 1201
            name="Change Accepted Taxon to Synonym">
1211 1202
      </command>-->
1203
      <command
1204
            categoryId="eu.etaxonomy.taxeditor.editor.taxon.name.command.category"
1205
            defaultHandler="eu.etaxonomy.taxeditor.editor.name.handler.DeleteTaxonBaseHandler"
1206
            id="eu.etaxonomy.taxeditor.editor.name.delete"
1207
            name="%command.name.45">
1208
      </command>
1212 1209
      <command
1213 1210
            categoryId="eu.etaxonomy.taxeditor.editor.taxon.name.command.category"
1214 1211
            defaultHandler="eu.etaxonomy.taxeditor.editor.name.handler.DeleteAllEmptyNamesHandler"
......
1222 1219
      <command
1223 1220
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1224 1221
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.CreateDescriptionElementHandler"
1225
            id="eu.etaxonomy.taxeditor.editor.description.createDescriptionElement"
1222
            id="eu.etaxonomy.taxeditor.editor.view.descriptive.command.createDescriptionElement"
1226 1223
            name="%command.name.10">
1227 1224
      </command>
1228 1225
      <command
1229 1226
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1230 1227
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.CreateDescriptionHandler"
1231
            id="eu.etaxonomy.taxeditor.description.commands.adddescription"
1228
            id="eu.etaxonomy.taxeditor.editor.view.descriptive.command.adddescription"
1232 1229
            name="%command.name.11">
1233 1230
      </command>
1234
      <command
1235
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1236
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.MoveDescriptionElementsHandler"
1237
            id="eu.etaxonomy.taxeditor.description.commands.moveDescriptionElements"
1238
            name="%command.name.12">
1239
      </command>
1240
      <command
1241
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1242
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.MoveDescriptionToOtherTaxonHandler"
1243
            id="eu.etaxonomy.taxeditor.editor.commands.description.moveDescriptionToTaxon"
1244
            name="%command.name.13">
1231
       <command
1232
             categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1233
             defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.DeleteHandler"
1234
             id="eu.etaxonomy.taxeditor.editor.view.descriptive.command.delete"
1235
             name="%command.name.48">
1245 1236
      </command>
1246 1237
      <category
1247 1238
            id="eu.etaxonomy.taxeditor.editor.view.uses.command.category"
......
1253 1244
            id="eu.etaxonomy.taxeditor.use.commands.adduse"
1254 1245
            name="%command.name.14">
1255 1246
      </command>
1247
      <command
1248
            categoryId="eu.etaxonomy.taxeditor.editor.view.uses.command.category"
1249
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.uses.handler.CreateUseRecordHandler"
1250
            id="eu.etaxonomy.taxeditor.editor.use.createUseRecord"
1251
            name="%command.name.16">
1252
      </command>
1256 1253
      <command
1257 1254
            categoryId="eu.etaxonomy.taxeditor.editor.view.uses.command.category"
1258 1255
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.uses.handler.CreateUseSummaryHandler"
......
1260 1257
            name="%command.name.15">
1261 1258
      </command>
1262 1259
      <command
1263
            categoryId="eu.etaxonomy.taxeditor.editor.view.uses.command.category"
1264
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.uses.handler.CreateUseRecordHandler"
1265
            id="eu.etaxonomy.taxeditor.editor.use.createUseRecord"
1266
            name="%command.name.16">
1260
            id="eu.etaxonomy.taxeditor.editor.use.command.delete"
1261
            name="%command.name.47">
1267 1262
      </command>
1268 1263
      <category
1269 1264
            id="eu.etaxonomy.taxeditor.editor.media.category"
......
1272 1267
      <command
1273 1268
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1274 1269
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.media.handler.MoveImageDownInListHandler"
1275
            id="taxeditor-editor.command.moveimgdown"
1270
            id="eu.etaxonomy.taxeditor.editor.media.command.moveimgdown"
1276 1271
            name="%command.name.19">
1277 1272
      </command>
1278 1273
      <command
1279 1274
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1280 1275
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.media.handler.AddImageGalleryHandler"
1281
            id="taxeditor-editor.command.newimagegallery"
1276
            id="eu.etaxonomy.taxeditor.editor.media.command.newimagegallery"
1282 1277
            name="%command.name.20">
1283 1278
      </command>
1284 1279
      <command
1285 1280
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1286 1281
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.media.handler.CreateMediaHandler"
1287
            id="taxeditor-editor.newimage"
1282
            id="eu.etaxonomy.taxeditor.editor.media.command.newimage"
1288 1283
            name="%command.name.21">
1289 1284
      </command>
1290 1285
      <command
1291 1286
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1292 1287
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.media.handler.AddExistingMediaHandler"
1293
            id="taxeditor-editor.useExistingImage"
1288
            id="eu.etaxonomy.taxeditor.editor.media.command.useExistingImage"
1294 1289
            name="%command.name.37">
1295 1290
      </command>
1296 1291
      <command
1297 1292
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1298 1293
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.media.handler.MoveImageUpInListHandler"
1299
            id="taxeditor-editor.command.moveimgup"
1294
            id="eu.etaxonomy.taxeditor.editor.media.command.moveimgup"
1300 1295
            name="%command.name.22">
1296
      </command>
1297
       <command
1298
            categoryId="eu.etaxonomy.taxeditor.editor.media.category"
1299
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.DeleteHandler"
1300
            id="eu.etaxonomy.taxeditor.editor.media.command.delete"
1301
            name="%command.name.49">
1301 1302
      </command>
1302 1303
      <category
1303 1304
            id="eu.etaxonomy.taxeditor.editor.new.category"
......
1361 1362
            id="eu.etaxonomy.taxeditor.key.command.applyLayout"
1362 1363
            name="%command.name.31">
1363 1364
      </command>
1365
      <command
1366
            defaultHandler="eu.etaxonomy.taxeditor.editor.key.polytomous.handler.DeleteNodeHandler"
1367
            id="eu.etaxonomy.taxeditor.key.polytomous.command.delete"
1368
            name="%command.name.50">
1369
      </command>
1364 1370
      <category
1365 1371
            id="eu.etaxonomy.taxeditor.editor.view.concept.category"
1366 1372
            name="%category.name.6">
......
1413 1419
            name="%command.name.42">
1414 1420
         <commandParameter
1415 1421
               id="eu.etaxonomy.taxeditor.editor.taxonParameter"
1416
               name="taxonUUID"
1422
               name="%commandParameter.name"
1417 1423
               optional="false"
1418 1424
               typeId="eu.etaxonomy.taxeditor.editor.taxonParameterType">
1419 1425
         </commandParameter>
......
1433 1439
            id="eu.etaxonomy.taxeditor.editor.derivate.deepDelete"
1434 1440
            name="%command.name.44">
1435 1441
      </command>
1442
      <command
1443
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1444
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.MoveDescriptionToOtherTaxonHandler"
1445
            id="eu.etaxonomy.taxeditor.editor.commands.description.moveDescriptionToTaxon"
1446
            name="%command.name.13">
1447
      </command>
1448
      <command
1449
            categoryId="eu.etaxonomy.taxeditor.editor.view.descriptive.command.category"
1450
            defaultHandler="eu.etaxonomy.taxeditor.editor.view.descriptive.handler.MoveDescriptionElementsHandler"
1451
            id="eu.etaxonomy.taxeditor.description.commands.moveDescriptionElements"
1452
            name="%command.name.12">
1453
      </command>
1454
        
1436 1455
   </extension>
1437 1456
   <extension
1438 1457
         point="org.eclipse.core.expressions.definitions">
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/handler/MoveSynonymToAnotherAcceptedTaxonHandler.java
1
package eu.etaxonomy.taxeditor.editor.name.handler;
2

  
3
import java.util.UUID;
4

  
5
import org.apache.log4j.Logger;
6
import org.eclipse.core.commands.AbstractHandler;
7
import org.eclipse.core.commands.ExecutionEvent;
8
import org.eclipse.core.commands.ExecutionException;
9
import org.eclipse.core.commands.common.NotDefinedException;
10
import org.eclipse.core.commands.operations.IUndoContext;
11
import org.eclipse.jface.dialogs.MessageDialog;
12
import org.eclipse.jface.viewers.StructuredSelection;
13
import org.eclipse.swt.widgets.Shell;
14
import org.eclipse.ui.IEditorInput;
15
import org.eclipse.ui.handlers.HandlerUtil;
16

  
17
import eu.etaxonomy.cdm.model.common.CdmBase;
18
import eu.etaxonomy.cdm.model.name.TaxonNameBase;
19
import eu.etaxonomy.cdm.model.taxon.Synonym;
20
import eu.etaxonomy.cdm.model.taxon.Taxon;
21
import eu.etaxonomy.cdm.model.taxon.TaxonNode;
22
import eu.etaxonomy.taxeditor.editor.EditorUtil;
23
import eu.etaxonomy.taxeditor.editor.MultiPageTaxonEditor;
24
import eu.etaxonomy.taxeditor.editor.TaxonEditorInput;
25
import eu.etaxonomy.taxeditor.editor.name.operation.MoveSynonymToAnotherAcceptedTaxonOperation;
26
import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled;
27
import eu.etaxonomy.taxeditor.ui.dialog.selection.TaxonNodeSelectionDialog;
28

  
29
public class MoveSynonymToAnotherAcceptedTaxonHandler extends AbstractHandler implements IPostOperationEnabled {
30
	private static final Logger logger = Logger
31
	.getLogger(MoveSynonymToAnotherAcceptedTaxonHandler.class);
32
	private MultiPageTaxonEditor editor;
33
	
34
	@Override
35
	public Object execute(ExecutionEvent event) throws ExecutionException {
36
		editor =  (MultiPageTaxonEditor) HandlerUtil.getActiveEditor(event);
37
		Shell shell = HandlerUtil.getActiveShell(event);
38
		IEditorInput input = editor.getEditorInput();
39
		if (!EditorUtil.forceUserSave(editor, shell)) {
40
			return null;
41
		}
42
		
43
		if (!(input instanceof TaxonEditorInput)) {
44
			logger.error("Editor input is not TaxonEditorInput");
45
			return null;
46
		}
47

  
48
		// Get synonym from selection
49
		StructuredSelection selection = (StructuredSelection) HandlerUtil.getCurrentSelection(event);
50
		if (!(selection.getFirstElement() instanceof Synonym)) {
51
			logger.error("Selection does not contain a Synonym");
52
			return null;
53
		}
54

  
55
		Synonym synonym = (Synonym) selection.getFirstElement();
56
		TaxonNode newParentNode = TaxonNodeSelectionDialog.select(HandlerUtil.getActiveShell(event), editor.getConversationHolder(), "Select new accepted taxon", null, null, null);
57
		Taxon oldParent = ((TaxonEditorInput)input).getTaxon();
58
	
59
			MoveSynonymToAnotherAcceptedTaxonOperation operation = new MoveSynonymToAnotherAcceptedTaxonOperation("Change accepted Taxon of Synonym", EditorUtil.getUndoContext(),
60
					oldParent.getUuid(), synonym.getUuid(), newParentNode.getTaxon(), editor);
61
			
62
			EditorUtil.executeOperation(operation);
63
	
64

  
65
		return null;
66
	}
67

  
68
	@Override
69
	public boolean postOperation(CdmBase objectAffectedByOperation) {
70
		// TODO Auto-generated method stub
71
		return false;
72
	}
73

  
74
	@Override
75
	public boolean onComplete() {
76
		// TODO Auto-generated method stub
77
		return false;
78
	}
79
	
80
	
81

  
82
}
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/view/descriptive/operation/CreateDescriptionElementOperation.java
40 40
public class CreateDescriptionElementOperation extends AbstractPostTaxonOperation {
41 41

  
42 42
	/** Constant <code>ID="eu.etaxonomy.taxeditor.editor.descripti"{trunked}</code> */
43
	public static final String ID = "eu.etaxonomy.taxeditor.editor.description.createDescriptionElement";
43
	public static final String ID = "eu.etaxonomy.taxeditor.editor.view.descriptive.command.createDescriptionElement";
44 44

  
45 45
	private final DescriptionBase<?> description;
46 46
	private final Feature feature;
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/view/descriptive/operation/DeleteTaxonDescriptionOperation.java
9 9

  
10 10
package eu.etaxonomy.taxeditor.editor.view.descriptive.operation;
11 11

  
12
import java.util.ArrayList;
13
import java.util.List;
14

  
12 15
import org.eclipse.core.commands.ExecutionException;
13 16
import org.eclipse.core.commands.operations.IUndoContext;
14 17
import org.eclipse.core.runtime.IAdaptable;
......
59 62

  
60 63
		monitor.worked(20);
61 64
		if (description != null){
62
			CdmStore.getService(IDescriptionService.class).deleteDescription(description);
65
			List<String> propertyPaths = new ArrayList<String>();
66
			propertyPaths.add("taxon");
67
			TaxonDescription loadedDescription = (TaxonDescription) CdmStore.getService(IDescriptionService.class).load(description.getUuid(), propertyPaths);
68
			CdmStore.getService(IDescriptionService.class).deleteDescription(loadedDescription);
63 69
			return postExecute(description);
64 70
		}
65 71
		return null;
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/view/media/MediaContentProvider.java
72 72
		}
73 73
		else if (parentElement instanceof DescriptionBase) {
74 74
			if (((DescriptionBase) parentElement).isImageGallery()) {
75
				return getImages((DescriptionBase) parentElement).toArray();
75
				List<Media> images =  getImages((DescriptionBase) parentElement);
76
				if (images != null){
77
					return images.toArray();
78
				} 
79
				return null;
80
				
76 81
			}
77 82
		}
78 83
		else if (parentElement instanceof DerivedUnit){
......
111 116
	/** {@inheritDoc} */
112 117
	@Override
113 118
    public boolean hasChildren(Object element) {
119
		if (getChildren(element)== null) {
120
			return false;
121
		}
114 122
		return (getChildren(element).length > 0);
115 123
	}
116 124

  
......
139 147
			if(elements.size() > 1){
140 148
				MessagingUtils.error(this.getClass(), "There should be one and only one description element to hold the images. Found: " + elements.size() + " InDescription ID: " + description.getUuid(), null);
141 149
			}
150
			if (!elements.isEmpty()){
151
				DescriptionElementBase element = elements.iterator().next();
152
				return element.getMedia();
153
			}
142 154

  
143
			DescriptionElementBase element = elements.iterator().next();
144

  
145
			return element.getMedia();
155
			
146 156
		}
147 157
		return null;
148 158
	}

Also available in: Unified diff