[overlord-commits] Overlord SVN: r974 - bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process.

overlord-commits at lists.jboss.org overlord-commits at lists.jboss.org
Wed Feb 17 06:14:15 EST 2010


Author: heiko.braun at jboss.com
Date: 2010-02-17 06:14:14 -0500 (Wed, 17 Feb 2010)
New Revision: 974

Modified:
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java
Log:
Disable instance operations when running riftsaw profile

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java	2010-02-17 11:13:50 UTC (rev 973)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java	2010-02-17 11:14:14 UTC (rev 974)
@@ -26,6 +26,7 @@
 import com.google.gwt.gen2.table.event.client.RowSelectionEvent;
 import com.google.gwt.gen2.table.event.client.RowSelectionHandler;
 import com.google.gwt.user.client.ui.Button;
+import com.google.gwt.user.client.ui.HTML;
 import com.mvc4g.client.Controller;
 import com.mvc4g.client.Event;
 import com.mvc4g.client.ViewInterface;
@@ -84,15 +85,14 @@
   {
 
     this.appContext = Registry.get(ApplicationContext.class);
+    // riftsaw?
+    isRiftsawInstance = appContext.getConfig().getProfileName().equals("BPEL Console");
 
     panel = new MosaicPanel();
     panel.setPadding(0);
     
     Registry.get(Controller.class).addView(ID, this);
     initialize();
-   
-    // riftsaw?
-    isRiftsawInstance = appContext.getConfig().getProfileName().equals("BPEL Console");
 
     callback.onSuccess(panel);
   }
@@ -231,13 +231,6 @@
 
         }
       }
-      )
-      {{
-          setVisible(!isRiftsawInstance);
-        }};
-      
-      toolBar.add(
-          startBtn
       );
 
 
@@ -277,9 +270,6 @@
       }
       );
 
-      toolBar.add(
-          terminateBtn
-      );
 
       deleteBtn = new Button("Delete", new ClickHandler()
       {
@@ -316,18 +306,30 @@
           }
         }
       }
-      )
-      {{
-          setVisible(!isRiftsawInstance);
-        }};
-      
-      toolBar.add(
-          deleteBtn
       );
 
-      startBtn.setEnabled(false);
-      terminateBtn.setEnabled(false);
-      deleteBtn.setEnabled(false);
+      if(!isRiftsawInstance)  // riftsaw doesn't support instance operations
+      {
+        toolBar.add(
+            startBtn
+        );
+
+        toolBar.add(
+            terminateBtn
+        );
+
+        toolBar.add(
+            deleteBtn
+        );
+
+        startBtn.setEnabled(false);
+        terminateBtn.setEnabled(false);
+        deleteBtn.setEnabled(false);
+      }
+      else
+      {
+        toolBar.add(new HTML(" "));
+      }
       
       toolBox.add(toolBar, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
       



More information about the overlord-commits mailing list