fixes #1401
authorn.hoffmann <n.hoffmann@localhost>
Thu, 14 Jan 2010 11:01:48 +0000 (11:01 +0000)
committern.hoffmann <n.hoffmann@localhost>
Thu, 14 Jan 2010 11:01:48 +0000 (11:01 +0000)
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/datasource/CdmDataSourceRepository.java
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/datasource/wizard/CdmDataSourceCredentialsWizardPage.java
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/model/AbstractUtility.java
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/operations/DeleteTaxonNodeOperation.java

index fb1cc284f1c0bc30ceda3e65c12307b0550acadc..e5dee2d70bdfd0dc1508042fc594c3915f9062cd 100644 (file)
@@ -125,8 +125,8 @@ public class CdmDataSourceRepository{
                \r
                if( dataSourceNomenclaturalCode != null && ! dataSourceNomenclaturalCode.equals(applicationNomenclaturalCode)){\r
                        PreferencesUtil.setPreferredNomenclaturalCode(dataSourceNomenclaturalCode);\r
-                       StoreUtil.warningDialog("Nomenclatural Code Change", "The Datasource that was just " +\r
-                                       "loaded has a different nomenclatural code than the one stored in Preferences." +\r
+                       StoreUtil.informationDialog("Nomenclatural Code Change", "The Datasource that was just " +\r
+                                       "loaded has a different nomenclatural code than the one stored in Preferences. " +\r
                                        "The nomenclatural code was changed in the application.");\r
                }\r
                return true;\r
index 398337f280b8c834772f0145e843b103a551274a..dec894354d7863713b18e7cffaee97cc3b806ffb 100644 (file)
@@ -175,7 +175,9 @@ public abstract class CdmDataSourceCredentialsWizardPage extends WizardPage impl
                        button.addSelectionListener(new SelectionAdapter() {
                                public void widgetSelected(SelectionEvent e) {
                                        nomenclaturalCode = (NomenclaturalCode) e.widget.getData();
-                                       updateDataSource();
+//                                     updateDataSource();
+//                                     checkPageComplete();
+                                       modifyText(null);
                                }
                        });
                }               
index 3c7c03f4263f8cb6158402f86f48bd83c65119aa..6b33554848519b0499d7adc2a8bc774541ab8ac8 100644 (file)
@@ -105,6 +105,10 @@ public abstract class AbstractUtility {
                warningDialog("Not yet implemented", "This functionality is not yet implemented.");
        }
        
+       public static void informationDialog(String title, String message){
+               MessageDialog.openInformation(getShell(), title, message);
+       }
+       
        public static void warningDialog(String title, String message){
                MessageDialog.openWarning(getShell(), title, message);
        }
index e29e5f63bfcaf6671e1b12b1584d294e080e160c..5d3e298bdc5d73959c47d20d523dd59af416e651 100644 (file)
@@ -83,9 +83,6 @@ public class DeleteTaxonNodeOperation extends AbstractPersistentPostOperation{
                        return Status.CANCEL_STATUS;\r
                }\r
                \r
-               \r
-               // delete the taxon in an isolated conversation\r
-//             deleteTaxonNodeIsolated(taxonNode.getUuid());\r
                taxonNode.delete();\r
                \r
                return postExecute(null);\r
@@ -108,29 +105,6 @@ public class DeleteTaxonNodeOperation extends AbstractPersistentPostOperation{
                        throws ExecutionException {\r
                // FIXME we have to add old citation\r
                parentNode.addChildTaxon(taxon, null, "", null);\r
-               // FIXME readding has to take place in an isolated conversation as well\r
-               // so that all the mediation magic does the rest for us\r
                return postExecute(null);\r
        }\r
-       \r
-       /**\r
-        * \r
-        * @param taxonNodeUuid\r
-        * @return\r
-        */\r
-       private boolean deleteTaxonNodeIsolated(UUID taxonNodeUuid){\r
-               // get a new conversation\r
-               ConversationHolder conversation = CdmStore.NewTransactionalConversation();\r
-               try{\r
-                       TaxonNode taxonNode = CdmStore.getTaxonTreeService().getTaxonNodeByUuid(taxonNodeUuid);\r
-                       \r
-                       boolean result = taxonNode.delete();\r
-                       \r
-                       // commit the conversation and throw it away\r
-                       conversation.commit(true);\r
-                       return result;\r
-               }finally{\r
-                       conversation.close();\r
-               }\r
-       }\r
 }\r