partial Fix of #4728
authorAlexander Oppermann <a.oppermann@bgbm.org>
Tue, 28 Apr 2015 16:40:53 +0000 (16:40 +0000)
committerAlexander Oppermann <a.oppermann@bgbm.org>
Tue, 28 Apr 2015 16:40:53 +0000 (16:40 +0000)
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/FixClassificationHierarchyHandler.java

index 2505dfc08a538724cda95a06d423a6b10ad125cc..1985a760ef47bd29ead9f430552772e4801ae474 100644 (file)
@@ -11,12 +11,15 @@ import org.eclipse.ui.handlers.HandlerUtil;
 import eu.etaxonomy.cdm.api.service.IClassificationService;
 import eu.etaxonomy.cdm.model.taxon.Classification;
 import eu.etaxonomy.taxeditor.model.MessagingUtils;
+import eu.etaxonomy.taxeditor.navigation.NavigationUtil;
+import eu.etaxonomy.taxeditor.navigation.navigator.TaxonNavigator;
 import eu.etaxonomy.taxeditor.store.CdmStore;
 
 public class FixClassificationHierarchyHandler extends AbstractHandler {
 
     private static final Logger logger = Logger.getLogger(FixClassificationHierarchyHandler.class);
 
+    TaxonNavigator taxonNavigator = (TaxonNavigator)NavigationUtil.showView(TaxonNavigator.ID);
     /*
      * (non-Javadoc)
      *
@@ -42,7 +45,8 @@ public class FixClassificationHierarchyHandler extends AbstractHandler {
 
                     MessagingUtils.messageDialog("Fix Hierarchy successful",
                             FixClassificationHierarchyHandler.class, "Operation 'Fix Hierarchy' was successful. New classification is " + newClassification.getTitleCache());
-
+                    //Success
+                    taxonNavigator.refresh();
                 } catch (Exception e) {
                     MessagingUtils.messageDialog("Failed to open Editor", FixClassificationHierarchyHandler.class,
                             "Could not open ChecklistView. The hierarchy is corrupted!", e);
@@ -51,4 +55,5 @@ public class FixClassificationHierarchyHandler extends AbstractHandler {
         }
         return null;
     }
+
 }