[overlord-commits] Overlord SVN: r921 - in bpm-console/trunk: gui/profiles/jbpm/src/main/resources and 5 other directories.

overlord-commits at lists.jboss.org overlord-commits at lists.jboss.org
Thu Jan 21 05:35:45 EST 2010


Author: heiko.braun at jboss.com
Date: 2010-01-21 05:35:44 -0500 (Thu, 21 Jan 2010)
New Revision: 921

Modified:
   bpm-console/trunk/gui/profiles/jbpm/src/main/resources/console.config.js
   bpm-console/trunk/gui/war/src/main/java/org/gwt/mosaic/ui/client/layout/MosaicPanel.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/MainLayout.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/PreferencesView.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/ServerStatusView.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/SettingsEditor.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/DeploymentDetailView.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/UpdateDeploymentDetailAction.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportEditor.java
   bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportLaunchPadView.java
   bpm-console/trunk/pom.xml
   bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/ConsoleConfig.java
   bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Editor.java
   bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Menu.java
   bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/MenuSection.java
   bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Workspace.java
Log:
More work on GWT 2.0 adoption

Modified: bpm-console/trunk/gui/profiles/jbpm/src/main/resources/console.config.js
===================================================================
--- bpm-console/trunk/gui/profiles/jbpm/src/main/resources/console.config.js	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/profiles/jbpm/src/main/resources/console.config.js	2010-01-21 10:35:44 UTC (rev 921)
@@ -1,6 +1,6 @@
 var consoleConfig = {
   profileName:          "jBPM Console",
-  logo:                 "jbpm_logo.png",
+  logo:                 "app/jbpm_logo.png",
   serverWebContext:     "/gwt-console-server",
   defaultEditor:        "org.jboss.bpm.console.client.task.TaskEditor",
   overallReportFile:   "overall_activity.rptdesign",

Modified: bpm-console/trunk/gui/war/src/main/java/org/gwt/mosaic/ui/client/layout/MosaicPanel.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/gwt/mosaic/ui/client/layout/MosaicPanel.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/gwt/mosaic/ui/client/layout/MosaicPanel.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -31,21 +31,21 @@
 {
   public MosaicPanel()
   {
-    super();    //To change body of overridden methods use File | Settings | File Templates.
+    super();    
   }
 
   protected MosaicPanel(Element elem)
   {
-    super(elem);    //To change body of overridden methods use File | Settings | File Templates.
+    super(elem);    
   }
 
   protected MosaicPanel(Element elem, LayoutManager layout)
   {
-    super(elem, layout);    //To change body of overridden methods use File | Settings | File Templates.
+    super(elem, layout);    
   }
 
   public MosaicPanel(LayoutManager layout)
   {
-    super(layout);    //To change body of overridden methods use File | Settings | File Templates.
+    super(layout);    
   }
 }

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/MainLayout.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/MainLayout.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/MainLayout.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -252,6 +252,7 @@
     final int width = Window.getClientWidth();
     final int height = Window.getClientHeight();
     //getViewport().onWindowResized(width, height);
+    //getViewport().getLayoutPanel().getResizableWidget().onResize(width, height);
     getViewport().getLayoutPanel().layout();
   }
 }

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/PreferencesView.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/PreferencesView.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/PreferencesView.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -23,17 +23,11 @@
 
 import com.google.gwt.event.dom.client.ClickEvent;
 import com.google.gwt.event.dom.client.ClickHandler;
-import com.google.gwt.user.client.ui.ClickListener;
 import com.google.gwt.user.client.ui.HTML;
 import com.google.gwt.user.client.ui.ListBox;
-import com.google.gwt.user.client.ui.Widget;
 import com.mvc4g.client.Controller;
 import com.mvc4g.client.ViewInterface;
-import org.gwt.mosaic.ui.client.layout.BoxLayout;
-import org.gwt.mosaic.ui.client.layout.BoxLayoutData;
-import org.gwt.mosaic.ui.client.layout.MosaicPanel;
-import org.gwt.mosaic.ui.client.layout.FillLayoutData;
-import org.gwt.mosaic.ui.client.CaptionLayoutPanel;
+import org.gwt.mosaic.ui.client.layout.*;
 import org.jboss.bpm.console.client.common.HeaderLabel;
 
 import java.util.List;
@@ -41,7 +35,7 @@
 /**
  * @author Heiko.Braun <heiko.braun at jboss.com>
  */
-public class PreferencesView extends CaptionLayoutPanel implements ViewInterface
+public class PreferencesView extends MosaicPanel implements ViewInterface
 {
 
   public final static String ID = PreferencesView.class.getName();
@@ -57,14 +51,13 @@
 
   public PreferencesView()
   {
-    super("User Preferences");
-        
+    super(new BoxLayout(BoxLayout.Orientation.VERTICAL));
+
     this.appContext = Registry.get(ApplicationContext.class);
-    //layout.add(new HeaderLabel("User Preferences"));
-    
-    MosaicPanel defaultToolPanel = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.HORIZONTAL));
-    
-    defaultToolPanel.add(
+    this.add(new HeaderLabel("User Preferences"), new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+
+    MosaicPanel layout = new MosaicPanel(new GridLayout(2,1));
+    layout.add(
         new HTML("<b>Default Tool</b><br>" +
         "Select the tool that should be loaded upon login.")
     );
@@ -72,7 +65,7 @@
     final List<Workspace.EditorRef> editors = appContext.getWorkpace().getEditors();
     final ListBox multiBox = new ListBox();
     multiBox.setVisibleItemCount(5);
-    defaultToolPanel.add(multiBox);
+    layout.add(multiBox);
 
     // init
     String prefEditor = Preferences.get(Preferences.BPM_DEFAULT_TOOL);    
@@ -100,6 +93,6 @@
         }
     );
 
-    this.add(defaultToolPanel);
+    this.add(layout, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
   }
 }

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/ServerStatusView.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/ServerStatusView.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/ServerStatusView.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -47,6 +47,7 @@
   public ServerStatusView(ApplicationContext appContext)
   {
     super();
+    setPadding(0);
     this.appContext = appContext;
   }
 
@@ -80,7 +81,11 @@
     for (int row = 0; row < status.getPlugins().size(); ++row)
     {
       PluginInfo p = status.getPlugins().get(row);
-      g.setText(row, 0, p.getType());      
+      String type = p.getType().substring(
+          p.getType().lastIndexOf(".")+1, p.getType().length()
+      );
+
+      g.setText(row, 0, type);
       
       final Image img = p.isAvailable() ?
           new Image("images/icons/confirm_small.png"):

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/SettingsEditor.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/SettingsEditor.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/SettingsEditor.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -31,6 +31,7 @@
 import org.gwt.mosaic.ui.client.DecoratedTabLayoutPanel;
 import org.gwt.mosaic.ui.client.TabLayoutPanel;
 import org.gwt.mosaic.ui.client.layout.*;
+import org.jboss.bpm.console.client.common.HeaderLabel;
 import org.jboss.bpm.console.client.icons.ConsoleIconBundle;
 
 /**
@@ -86,7 +87,7 @@
     layout();
   }
 
-  private CaptionLayoutPanel createPrefPanel()
+  private MosaicPanel createPrefPanel()
   {
     PreferencesView prefView = new PreferencesView();
     controller.addView(PreferencesView.ID, prefView);
@@ -94,52 +95,41 @@
     return prefView;
   }
 
-  private CaptionLayoutPanel createSystemPanel()
+  private MosaicPanel createSystemPanel()
   {
-    final CaptionLayoutPanel captionPanel = new CaptionLayoutPanel("System Settings");
 
     MosaicPanel layoutPanel = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
 
     // console info
-    Label console = new Label("Console Info");    
+    HeaderLabel console = new HeaderLabel("Console Info");
     layoutPanel.add(console, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
-    Grid g1 = new Grid(1,2);
-    g1.setWidget(0,0, new HTML("Version:"));
-    g1.setWidget(0,1, new HTML(Version.VERSION));
-    g1.getColumnFormatter().setWidth(0, "20%");
+    MosaicPanel layout1 = new MosaicPanel(new GridLayout(2,1));
+    layout1.add(new HTML("Version:"));
+    layout1.add(new HTML(Version.VERSION));
+    
+    layoutPanel.add(layout1, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
-    layoutPanel.add(g1, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
-
     // server info
-    Label server = new Label("Server Info");
+    HeaderLabel server = new HeaderLabel("Server Info");
     layoutPanel.add(server, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
     ServerStatusView serverStatus = new ServerStatusView(appContext);
     serverStatus.initialize();
 
-    Grid g2 = new Grid(1,2);
-    g2.setWidget(0,0, new HTML("Host:"));
-    g2.setWidget(0,1, new HTML(appContext.getConfig().getConsoleServerUrl()));
+    MosaicPanel layout2 = new MosaicPanel(new GridLayout(2,2));
+    layout2.add(new HTML("Host:"));
+    layout2.add(new HTML(appContext.getConfig().getConsoleServerUrl()));
 
-    g2.getColumnFormatter().setWidth(0, "20%");
+    layout2.add(new Label("Plugins:"));
+    layout2.add(serverStatus);
 
-    layoutPanel.add(g2, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+    layoutPanel.add(layout2, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
-    MosaicPanel pluginPanel = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
-    pluginPanel.setPadding(0);
-    Label label = new Label("Plugins:");
-
-    pluginPanel.add(label);
-    pluginPanel.add(serverStatus);
-
-    layoutPanel.add(pluginPanel, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
-
     // view and actions
     super.controller.addView(ServerStatusView.ID, serverStatus);
 
-    captionPanel.add(layoutPanel);
-    return captionPanel;
+    return layoutPanel;
   }
 
   public String getEditorId()

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/DeploymentDetailView.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/DeploymentDetailView.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/DeploymentDetailView.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -21,8 +21,10 @@
  */
 package org.jboss.bpm.console.client.engine;
 
+import com.google.gwt.event.dom.client.ClickEvent;
+import com.google.gwt.event.dom.client.ClickHandler;
+import com.google.gwt.user.client.ui.Button;
 import com.google.gwt.user.client.ui.ChangeListener;
-import com.google.gwt.user.client.ui.ClickListener;
 import com.google.gwt.user.client.ui.Widget;
 import com.mvc4g.client.Controller;
 import com.mvc4g.client.Event;
@@ -51,8 +53,8 @@
 
   private ResourcePanel resourcePanel;
 
-  ToolButton suspendBtn;
-  ToolButton resumeBtn;
+  Button suspendBtn;
+  Button resumeBtn;
   
   public DeploymentDetailView()
   {
@@ -64,9 +66,11 @@
     propLayout.add(grid, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
 
 
-    suspendBtn =  new ToolButton("Suspend", new ClickListener() {
-      public void onClick(Widget sender) {
+    suspendBtn =  new Button("Suspend", new ClickHandler() {
 
+      public void onClick(ClickEvent clickEvent)
+      {
+
         DeploymentRef deploymentRef = getSelection();
         if(deploymentRef!=null)
         {
@@ -94,9 +98,10 @@
       }
     }
     );
-    resumeBtn =  new ToolButton("Resume", new ClickListener() {
-      public void onClick(Widget sender) {
 
+    resumeBtn =  new Button("Resume", new ClickHandler() {
+      public void onClick(ClickEvent clickEvent)
+      {        
         DeploymentRef deploymentRef = getSelection();
         if(deploymentRef!=null)
         {
@@ -125,8 +130,10 @@
     }
     );
 
-    propLayout.add(suspendBtn);
-    propLayout.add(resumeBtn);
+    MosaicPanel btnLayout = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
+    btnLayout.add(suspendBtn, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+    btnLayout.add(resumeBtn, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+    propLayout.add(btnLayout);
     
     // properties
     final DeckLayoutPanel deck = new DeckLayoutPanel();

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/UpdateDeploymentDetailAction.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/UpdateDeploymentDetailAction.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/engine/UpdateDeploymentDetailAction.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -46,6 +46,6 @@
     {
       // update view
       view.update(ref);
-    }
+    }   
   }
 }

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportEditor.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportEditor.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportEditor.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -115,6 +115,8 @@
       // load report config
       controller.handleEvent(new Event(UpdateReportConfigAction.ID, null));
 
+      appContext.refreshView();
+      
       this.isInitialized = true;
     }
   }

Modified: bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportLaunchPadView.java
===================================================================
--- bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportLaunchPadView.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/report/ReportLaunchPadView.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -22,6 +22,8 @@
 package org.jboss.bpm.console.client.report;
 
 import com.google.gwt.core.client.GWT;
+import com.google.gwt.event.dom.client.ClickEvent;
+import com.google.gwt.event.dom.client.ClickHandler;
 import com.google.gwt.user.client.ui.*;
 import com.mvc4g.client.Controller;
 import com.mvc4g.client.Event;
@@ -57,28 +59,32 @@
   private Controller controller;
 
   private WidgetWindowPanel window;
+  private MosaicPanel inner;
 
   public ReportLaunchPadView()
   {
     super(new BoxLayout(BoxLayout.Orientation.VERTICAL));
+    
     this.setPadding(10);
     HTML html = new HTML("The following reports are available.<br/> " +
         "Please note that rendering may take a while.");
-    this.add(html);
-  
+
+    inner = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
+
+    this.add(html, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+    this.add(inner, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
+
   }
 
   public void update(List<ReportReference> reports)
   {
     ConsoleIconBundle icons = GWT.create(ConsoleIconBundle.class);
+    inner.clear();
 
     for(final ReportReference reportRef : reports)
     {
       final boolean hasParameters = reportRef.getParameterMetaData().size()>0;
 
-      //p.add(new HeaderLabel(group.name));
-      MosaicPanel inner = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.VERTICAL));
-
       // a single report description
       MosaicPanel row = new MosaicPanel(new BoxLayout(BoxLayout.Orientation.HORIZONTAL));
 
@@ -88,17 +94,19 @@
           AbstractImagePrototype.create(icons.reportInstanceIcon()), 
           reportRef.getTitle()
       );
-      header.setWidth("95%");
       desc.add(header);
+
+      desc.add(new HTML(reportRef.getTitle()));
+      
       String description = reportRef.getDescription()!=null ? reportRef.getDescription() : "";
       desc.add(new HTML(description));
-      row.add(desc,new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
+      row.add(desc, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
       // render button
       row.add(new Button("Render",
-          new ClickListener()
+          new ClickHandler()
           {
-            public void onClick(Widget widget)
+            public void onClick(ClickEvent clickEvent)
             {
               if(hasParameters)
               {
@@ -132,16 +140,15 @@
                 );
               }
             }
-          })
+          })          
       );
 
 
       inner.add(row, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
-      this.add(inner, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
     }
 
-
+    this.invalidate();
     Registry.get(ApplicationContext.class).refreshView();
   }
 

Modified: bpm-console/trunk/pom.xml
===================================================================
--- bpm-console/trunk/pom.xml	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/pom.xml	2010-01-21 10:35:44 UTC (rev 921)
@@ -43,7 +43,7 @@
         <gwt.version>2.0.0</gwt.version>
 
         <gwt.maven>1.2.0-11137</gwt.maven>
-        <gwt-log.version>2.5.2</gwt-log.version>
+        <gwt-log.version>3.0.0</gwt-log.version>
         <jaf.version>1.1</jaf.version>
         <javax.ejb.version>3.0</javax.ejb.version>
         <javax.jaxb.version>2.1</javax.jaxb.version>

Modified: bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/ConsoleConfig.java
===================================================================
--- bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/ConsoleConfig.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/ConsoleConfig.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -99,7 +99,7 @@
     {
       String baseUrl = GWT.getModuleBaseURL();
       host = baseUrl.substring(
-          0, baseUrl.indexOf("org.jboss.bpm.console.Application")
+          0, baseUrl.indexOf("app")
       );
     }
 

Modified: bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Editor.java
===================================================================
--- bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Editor.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Editor.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -22,10 +22,7 @@
 package org.jboss.bpm.console.client;
 
 import com.mvc4g.client.Controller;
-import com.google.gwt.user.client.Window;
-import org.gwt.mosaic.ui.client.layout.LayoutPanel;
 import org.gwt.mosaic.ui.client.layout.BorderLayout;
-import org.jboss.bpm.console.client.LazyPanel;
 
 
 /**
@@ -48,7 +45,7 @@
  *
  * @author Heiko.Braun <heiko.braun at jboss.com>
  */
-public abstract class Editor extends LayoutPanel implements LazyPanel
+public abstract class Editor extends org.gwt.mosaic.ui.client.layout.LayoutPanel implements LazyPanel
 {
   protected ApplicationContext appContext;
 

Modified: bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Menu.java
===================================================================
--- bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Menu.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Menu.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -22,15 +22,14 @@
 package org.jboss.bpm.console.client;
 
 
+import com.mvc4g.client.Controller;
+import com.mvc4g.client.ViewInterface;
 import org.gwt.mosaic.ui.client.StackLayoutPanel;
 import org.gwt.mosaic.ui.client.layout.BoxLayout;
 import org.gwt.mosaic.ui.client.layout.BoxLayoutData;
-import org.gwt.mosaic.ui.client.layout.LayoutPanel;
-import com.mvc4g.client.ViewInterface;
-import com.mvc4g.client.Controller;
 
-import java.util.Map;
 import java.util.HashMap;
+import java.util.Map;
 
 /**
  * The main menu on the left hand.
@@ -38,9 +37,9 @@
  *
  * @author Heiko.Braun <heiko.braun at jboss.com>
  */
-public class Menu extends LayoutPanel implements ViewInterface
+public class Menu extends org.gwt.mosaic.ui.client.layout.LayoutPanel implements ViewInterface
 {  
-  private StackLayoutPanel stack;  
+  private StackLayoutPanel stack;
   private Controller controller;
 
   private Map<String, Integer> name2Index = new HashMap<String, Integer>();
@@ -77,6 +76,6 @@
 
     int index = name2Index.get(editorId);
     stack.showStack(index);
-    stack.layout();
+    this.layout();
   }
 }

Modified: bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/MenuSection.java
===================================================================
--- bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/MenuSection.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/MenuSection.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -32,7 +32,7 @@
  *
  * @author Heiko.Braun <heiko.braun at jboss.com>
  */
-public class MenuSection extends LayoutPanel
+public class MenuSection extends org.gwt.mosaic.ui.client.layout.LayoutPanel
 {
 
   private HTML menuTitle;

Modified: bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Workspace.java
===================================================================
--- bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Workspace.java	2010-01-21 08:17:55 UTC (rev 920)
+++ bpm-console/trunk/workspace/workspace-api/src/main/java/org/jboss/bpm/console/client/Workspace.java	2010-01-21 10:35:44 UTC (rev 921)
@@ -24,10 +24,9 @@
 import com.google.gwt.user.client.Command;
 import com.google.gwt.user.client.DeferredCommand;
 import org.gwt.mosaic.ui.client.DeckLayoutPanel;
-import org.gwt.mosaic.ui.client.layout.LayoutPanel;
 
+import java.util.ArrayList;
 import java.util.List;
-import java.util.ArrayList;
 
 /**
  * Maintains {@link Editor}'s
@@ -73,21 +72,23 @@
 
   public void showEditor(final String editorId, final String viewId)
   {
-    EditorDeck deck = findEditor(editorId);
+    final EditorDeck deck = findEditor(editorId);
     if(null==deck)
       throw new IllegalArgumentException("No such editor: " +editorId);
 
-    // display editor
-    this.showWidget(deck.index);
+    Workspace.this.showWidget(deck.index);
     deck.editor.initialize();
     deck.editor.showView(viewId);
-
-    DeferredCommand.addCommand(new Command() {
-      public void execute() {
-        menu.toggle(editorId);
-      }
-    });
-
+    
+    // display editor
+    DeferredCommand.addCommand(
+        new Command()
+        {
+          public void execute() {
+            menu.toggle(editorId);
+          }
+        }
+    );
   }
 
   private EditorDeck createDeck(Editor editor)
@@ -126,7 +127,7 @@
     return result;
   }
 
-  private class EditorDeck extends LayoutPanel
+  private class EditorDeck extends org.gwt.mosaic.ui.client.layout.LayoutPanel
   {
     Editor editor;
     int index;



More information about the overlord-commits mailing list