[jbpm-commits] JBoss JBPM SVN: r4793 - in projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client: task and 1 other directory.

do-not-reply at jboss.org do-not-reply at jboss.org
Tue May 12 08:48:49 EDT 2009


Author: heiko.braun at jboss.com
Date: 2009-05-12 08:48:49 -0400 (Tue, 12 May 2009)
New Revision: 4793

Added:
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceDetailView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/ProcessDetailView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateInstanceDetailAction.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateProcessDetailAction.java
Modified:
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/DefinitionListView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/AssignedTasksView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/OpenTasksView.java
   projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/TaskDetailView.java
Log:
Fix JBPM-2218: Closing the task form window should refresh the task list. Also added process definition and instance detail properties

Modified: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/DefinitionListView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/DefinitionListView.java	2009-05-12 10:45:58 UTC (rev 4792)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/DefinitionListView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -32,9 +32,7 @@
 import org.gwt.mosaic.ui.client.ToolBar;
 import org.gwt.mosaic.ui.client.ToolButton;
 import org.gwt.mosaic.ui.client.MessageBox;
-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 org.gwt.mosaic.ui.client.layout.*;
 import org.gwt.mosaic.ui.client.list.DefaultListModel;
 import org.jboss.bpm.console.client.model.ProcessDefinitionRef;
 import org.jboss.bpm.console.client.LazyPanel;
@@ -83,7 +81,7 @@
       listBox =
           new ListBox<ProcessDefinitionRef>(
               new String[] {
-                  "Process ID", "Name", "Key", "Version"}
+                  "Process ID", "Version", "Name"}
           );
 
 
@@ -95,14 +93,11 @@
               listBox.setText(row, column, item.getId());
               break;
             case 1:
-              listBox.setText(row, column, item.getName());
+              listBox.setText(row, column, String.valueOf(item.getVersion()));
               break;
             case 2:
-              listBox.setText(row, column, item.getKey());
+              listBox.setText(row, column, item.getName());
               break;
-            case 3:
-              listBox.setText(row, column, String.valueOf(item.getVersion()));
-              break;
             default:
               throw new RuntimeException("Unexpected column size");
           }
@@ -116,13 +111,32 @@
           int index = listBox.getSelectedIndex();
           if(index!=-1)
           {
+            ProcessDefinitionRef item = listBox.getItem(index);
+
+            // update details
             controller.handleEvent(
+                new Event(UpdateProcessDetailAction.ID, item)
+            );
+
+            // load instances
+            controller.handleEvent(
                 new Event(
                     LoadInstancesAction.ID,
-                    listBox.getItem( index )
+                    item
                 )
             );
           }
+          else
+          {
+            if(isInitialized())
+            {
+              // update details
+              controller.handleEvent(
+                  new Event(UpdateProcessDetailAction.ID, null)
+              );
+            }
+          }
+
         }
       });
 
@@ -158,9 +172,9 @@
               ProcessDefinitionRef definitionRef = getSelection();
               if(definitionRef!=null)
               {
-              controller.handleEvent(
-                  new Event(DeleteDefinitionAction.ID, definitionRef)
-              );
+                controller.handleEvent(
+                    new Event(DeleteDefinitionAction.ID, definitionRef)
+                );
               }
               else
               {
@@ -170,14 +184,24 @@
           }
           )
       );
-      
+
       toolBox.add(toolBar, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
 
       this.definitionList.add(toolBox, new BoxLayoutData(BoxLayoutData.FillStyle.HORIZONTAL));
       this.definitionList.add(listBox, new BoxLayoutData(BoxLayoutData.FillStyle.BOTH));
 
-      this.add(definitionList);
+      // layout
+      LayoutPanel layout = new LayoutPanel(new BorderLayout());
+      layout.add(definitionList, new BorderLayoutData(BorderLayout.Region.CENTER));
 
+      // details
+      ProcessDetailView detailsView = new ProcessDetailView();
+      controller.addView(ProcessDetailView.ID, detailsView);
+      controller.addAction(UpdateProcessDetailAction.ID, new UpdateProcessDetailAction());
+      layout.add(detailsView, new BorderLayoutData(BorderLayout.Region.SOUTH));
+
+      this.add(layout);
+
       isInitialized = true;
     }
   }

Added: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceDetailView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceDetailView.java	                        (rev 0)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceDetailView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -0,0 +1,79 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.bpm.console.client.process;
+
+import com.mvc4g.client.Controller;
+import com.mvc4g.client.ViewInterface;
+import org.gwt.mosaic.ui.client.CaptionLayoutPanel;
+import org.jboss.bpm.console.client.common.PropertyGrid;
+import org.jboss.bpm.console.client.model.ProcessInstanceRef;
+
+/**
+ * @author Heiko.Braun <heiko.braun at jboss.com>
+ */
+public class InstanceDetailView extends CaptionLayoutPanel implements ViewInterface
+{
+  public final static String ID = ProcessDetailView.class.getName();
+
+  private Controller controller;
+
+  private PropertyGrid grid;
+
+  private ProcessInstanceRef currentInstance;
+
+  public InstanceDetailView()
+  {
+    super("Instance details");
+    super.setStyleName("bpm-detail-panel");
+
+    grid = new PropertyGrid(
+        new String[] {"ID:", "Key:", "State", "Start Date:"}
+    );
+
+    this.add(grid);
+  }
+
+  public void setController(Controller controller)
+  {
+    this.controller = controller;
+  }
+
+  public void update(ProcessInstanceRef instance)
+  {
+    this.currentInstance = instance;
+
+    String[] values = new String[] {
+        instance.getId(),
+        instance.getKey(),
+        String.valueOf( instance.getState() ),
+        String.valueOf( instance.getStartDate() )
+    };
+
+    grid.update(values);
+  }
+
+  public void clear()
+  {
+    grid.clear();
+    this.currentInstance = null;
+  }
+}

Modified: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java	2009-05-12 10:45:58 UTC (rev 4792)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/InstanceListView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -21,25 +21,22 @@
  */
 package org.jboss.bpm.console.client.process;
 
+import com.google.gwt.core.client.GWT;
+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.google.gwt.core.client.GWT;
 import com.mvc4g.client.Controller;
-import com.mvc4g.client.ViewInterface;
 import com.mvc4g.client.Event;
 import org.gwt.mosaic.ui.client.ListBox;
+import org.gwt.mosaic.ui.client.MessageBox;
 import org.gwt.mosaic.ui.client.ToolBar;
 import org.gwt.mosaic.ui.client.ToolButton;
-import org.gwt.mosaic.ui.client.MessageBox;
-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 org.gwt.mosaic.ui.client.layout.*;
 import org.gwt.mosaic.ui.client.list.DefaultListModel;
+import org.jboss.bpm.console.client.common.AbstractView;
+import org.jboss.bpm.console.client.icons.ConsoleIconBundle;
 import org.jboss.bpm.console.client.model.ProcessDefinitionRef;
 import org.jboss.bpm.console.client.model.ProcessInstanceRef;
-import org.jboss.bpm.console.client.LazyPanel;
-import org.jboss.bpm.console.client.icons.ConsoleIconBundle;
-import org.jboss.bpm.console.client.common.AbstractView;
 
 import java.util.List;
 
@@ -108,6 +105,32 @@
         }
       });
 
+      listBox.addChangeListener(new ChangeListener()
+      {
+        public void onChange(Widget widget)
+        {
+          int index = listBox.getSelectedIndex();
+          if(index!=-1)
+          {
+            ProcessInstanceRef item = listBox.getItem(index);
+
+            // update details
+            controller.handleEvent(
+                new Event(UpdateInstanceDetailAction.ID, item)
+            );            
+          }
+          else
+          {
+            if(isInitialized()) // first call don't have a controller association
+            {
+              controller.handleEvent(
+                  new Event(UpdateInstanceDetailAction.ID, null)
+              );
+            }
+          }
+
+        }
+      });
       // toolbar
       final LayoutPanel toolBox = new LayoutPanel();
       toolBox.setPadding(0);
@@ -183,8 +206,18 @@
       if(this.cachedInstances!=null)
         bindData(this.cachedInstances);
 
-      this.add(instanceList);
+      // layout
+      LayoutPanel layout = new LayoutPanel(new BorderLayout());
+      layout.add(instanceList, new BorderLayoutData(BorderLayout.Region.CENTER));
 
+      // details
+      InstanceDetailView detailsView = new InstanceDetailView();
+      controller.addView(InstanceDetailView.ID, detailsView);
+      controller.addAction(UpdateInstanceDetailAction.ID, new UpdateInstanceDetailAction());
+      layout.add(detailsView, new BorderLayoutData(BorderLayout.Region.SOUTH));
+
+      this.add(layout);
+
       isInitialized = true;
 
     }

Added: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/ProcessDetailView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/ProcessDetailView.java	                        (rev 0)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/ProcessDetailView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -0,0 +1,80 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.bpm.console.client.process;
+
+import com.mvc4g.client.ViewInterface;
+import com.mvc4g.client.Controller;
+import org.jboss.bpm.console.client.common.PropertyGrid;
+import org.jboss.bpm.console.client.model.ProcessDefinitionRef;
+import org.gwt.mosaic.ui.client.CaptionLayoutPanel;
+
+/**
+ * @author Heiko.Braun <heiko.braun at jboss.com>
+ */
+public class ProcessDetailView extends CaptionLayoutPanel implements ViewInterface
+{
+  public final static String ID = ProcessDetailView.class.getName();
+
+  private Controller controller;
+
+  private PropertyGrid grid;
+
+  private ProcessDefinitionRef currentProcess;
+
+  public ProcessDetailView()
+  {
+    super("Process details");
+    super.setStyleName("bpm-detail-panel");
+
+    grid = new PropertyGrid(
+        new String[] {"ID:", "Key:", "Name:", "Package:", "Description:"}
+    );
+
+    this.add(grid);    
+  }
+
+  public void setController(Controller controller)
+  {
+    this.controller = controller;
+  }
+
+  public void update(ProcessDefinitionRef process)
+  {
+    this.currentProcess = process;
+
+    String[] values = new String[] {
+        process.getId(),
+        process.getKey(),
+        process.getName(),
+        process.getPackageName(),
+        process.getDescription()        
+    };
+
+    grid.update(values);
+  }
+
+  public void clear()
+  {
+    grid.clear();
+    this.currentProcess = null;
+  }
+}

Added: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateInstanceDetailAction.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateInstanceDetailAction.java	                        (rev 0)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateInstanceDetailAction.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.bpm.console.client.process;
+
+import com.mvc4g.client.ActionInterface;
+import com.mvc4g.client.Controller;
+import org.jboss.bpm.console.client.model.ProcessInstanceRef;
+
+/**
+ * @author Heiko.Braun <heiko.braun at jboss.com>
+ */
+public class UpdateInstanceDetailAction implements ActionInterface
+{
+  public final static String ID = UpdateInstanceDetailAction.class.getName();
+
+  public void execute(Controller controller, Object object)
+  {
+    ProcessInstanceRef instance = object!=null ? (ProcessInstanceRef)object : null;
+    InstanceDetailView view = (InstanceDetailView)controller.getView(InstanceDetailView.ID);
+
+    if(instance!=null)
+      view.update(instance);
+    else
+      view.clear();
+  }
+}

Added: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateProcessDetailAction.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateProcessDetailAction.java	                        (rev 0)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/process/UpdateProcessDetailAction.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.bpm.console.client.process;
+
+import com.mvc4g.client.ActionInterface;
+import com.mvc4g.client.Controller;
+import org.jboss.bpm.console.client.model.ProcessDefinitionRef;
+
+/**
+ * @author Heiko.Braun <heiko.braun at jboss.com>
+ */
+public class UpdateProcessDetailAction implements ActionInterface
+{
+  public final static String ID = UpdateProcessDetailAction.class.getName();
+
+  public void execute(Controller controller, Object object)
+  {
+    ProcessDefinitionRef process = object!=null ? (ProcessDefinitionRef)object : null;
+    ProcessDetailView view = (ProcessDetailView)controller.getView(ProcessDetailView.ID);
+
+    if(process!=null)
+      view.update(process);
+    else
+      view.clear();
+  }
+}

Modified: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/AssignedTasksView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/AssignedTasksView.java	2009-05-12 10:45:58 UTC (rev 4792)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/AssignedTasksView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -113,6 +113,12 @@
                     new Event(UpdateDetailsAction.ID, new DetailViewEvent("AssignedDetailView", task))
                 );
               }
+              else
+              {
+                controller.handleEvent(
+                    new Event(UpdateDetailsAction.ID, new DetailViewEvent("AssignedDetailView", null))
+                );
+              }
             }
           }
       );
@@ -143,7 +149,7 @@
             public void onClick(Widget sender) {
 
               TaskRef selection = getSelection();
-             
+
               if(selection!=null)
               {
                 if(selection.getUrl()!=null && !selection.getUrl().equals(""))
@@ -208,14 +214,16 @@
     windowPanel = new WindowPanel(task.getName());
     windowPanel.setAnimationEnabled(true);
     windowPanel.setSize("320px", "240px");
-   
+
     windowPanel.addWindowCloseListener(new WindowCloseListener() {
       public void onWindowClosed() {
-        windowPanel = null;        
-        frame = null;
         controller.handleEvent(
-            new Event(LoadTasksAction.ID, null)
+            new Event(LoadTasksAction.ID, getAssignedIdentity())
         );
+
+        windowPanel = null;
+        frame = null;
+
       }
 
       public String onWindowClosing() {
@@ -229,7 +237,7 @@
     DOM.setStyleAttribute(frame.getElement(), "border", "none");
 
     windowPanel.setWidget(frame);
-    
+
     WindowUtil.addMaximizeButton(windowPanel, Caption.CaptionRegion.RIGHT);
     WindowUtil.addMinimizeButton(windowPanel, Caption.CaptionRegion.RIGHT);
 

Modified: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/OpenTasksView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/OpenTasksView.java	2009-05-12 10:45:58 UTC (rev 4792)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/OpenTasksView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -112,10 +112,19 @@
                     new Event(UpdateDetailsAction.ID, new DetailViewEvent("OpenDetailView", task))
                 );
               }
+              else
+              {
+                if(isInitialized())
+                {
+                  controller.handleEvent(
+                      new Event(UpdateDetailsAction.ID, new DetailViewEvent("OpenDetailView", null))
+                  );
+                }
+              }
             }
           }
       );
-      
+
       // toolbar
       final LayoutPanel toolBox = new LayoutPanel();
       toolBox.setPadding(0);
@@ -143,7 +152,7 @@
               TaskRef selection = getSelection();
 
               if(selection!=null)
-              {                
+              {
                 controller.handleEvent(
                     new Event(
                         ClaimTaskAction.ID,

Modified: projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/TaskDetailView.java
===================================================================
--- projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/TaskDetailView.java	2009-05-12 10:45:58 UTC (rev 4792)
+++ projects/gwt-console/trunk/gui/war/src/main/java/org/jboss/bpm/console/client/task/TaskDetailView.java	2009-05-12 12:48:49 UTC (rev 4793)
@@ -24,14 +24,13 @@
 import com.mvc4g.client.Controller;
 import com.mvc4g.client.ViewInterface;
 import org.gwt.mosaic.ui.client.CaptionLayoutPanel;
-import org.gwt.mosaic.ui.client.layout.LayoutPanel;
 import org.jboss.bpm.console.client.common.PropertyGrid;
 import org.jboss.bpm.console.client.model.TaskRef;
 
 /**
  * @author Heiko.Braun <heiko.braun at jboss.com>
  */
-public class TaskDetailView extends LayoutPanel implements ViewInterface
+public class TaskDetailView extends CaptionLayoutPanel implements ViewInterface
 {
   public final static String ID = TaskDetailView.class.getName();
   
@@ -45,18 +44,18 @@
 
   public TaskDetailView(boolean openView)
   {
+
+    // render
+    super("Task details");
+    super.setStyleName("bpm-detail-panel");
+
     this.openView = openView;
     
-    // render
-    CaptionLayoutPanel panel = new CaptionLayoutPanel("Task details");
-    panel.setStyleName("bpm-detail-panel");
     grid = new PropertyGrid(
         new String[] {"ID:", "Name:", "Description:"}
     );
     
-    panel.add(grid);
-    
-    this.add(panel);
+    this.add(grid);    
   }
 
   public void setController(Controller controller)




More information about the jbpm-commits mailing list