[jboss-cvs] jboss-portal/core/src/main/org/jboss/portal/core/command ...

Chris Laprun chris.laprun at jboss.com
Wed Jul 19 13:17:41 EDT 2006


  User: claprun 
  Date: 06/07/19 13:17:41

  Modified:    core/src/main/org/jboss/portal/core/command 
                        MarkupCommand.java
  Log:
  JBPORTAL-958:
  - Separated concerns: states and modes do not contain ordering logic anymore.
  - Ordering is done in DivDecorationRenderer.
  - Removed Actionable and BaseActionable.
  - Moved constants for action map to WindowResult.
  
  Revision  Changes    Path
  1.35      +9 -12     jboss-portal/core/src/main/org/jboss/portal/core/command/MarkupCommand.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MarkupCommand.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-portal/core/src/main/org/jboss/portal/core/command/MarkupCommand.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- MarkupCommand.java	19 Jul 2006 14:41:37 -0000	1.34
  +++ MarkupCommand.java	19 Jul 2006 17:17:41 -0000	1.35
  @@ -30,7 +30,6 @@
   import org.jboss.portal.core.model.portal.PortalObjectPermission;
   import org.jboss.portal.core.model.portal.Window;
   import org.jboss.portal.identity.User;
  -import org.jboss.portal.portlet.Actionable;
   import org.jboss.portal.portlet.Mode;
   import org.jboss.portal.portlet.WindowState;
   import org.jboss.portal.portlet.info.ModeInfo;
  @@ -81,7 +80,7 @@
    * RenderPageCommand and the RenderRegionCommand.</p>
    *
    * @author <a href="mailto:mholzner at novell.com">Martin Holzner</a>
  - * @version $Revision: 1.34 $
  + * @version $Revision: 1.35 $
    */
   public abstract class MarkupCommand extends PortalObjectCommand
   {
  @@ -575,8 +574,8 @@
                  windowTitle = "Portlet unavailable";
                  contentChars = "Portlet unavailable";
                  actionMap = new HashMap();
  -               actionMap.put(Actionable.MODES_KEY, Collections.EMPTY_LIST);
  -               actionMap.put(Actionable.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
  +               actionMap.put(WindowResult.MODES_KEY, Collections.EMPTY_LIST);
  +               actionMap.put(WindowResult.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
                  responseProps = new Properties();
                  return new ModifiableWindowResult(windowTitle, contentChars, actionMap, windowProps, responseProps, headerChars);
               }
  @@ -600,8 +599,8 @@
            }
            if (SHOW.equals(cfg.getProperty(WINDOW_ACCESS_DENIED)))
            {
  -            actionMap.put(Actionable.MODES_KEY, Collections.EMPTY_LIST);
  -            actionMap.put(Actionable.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
  +            actionMap.put(WindowResult.MODES_KEY, Collections.EMPTY_LIST);
  +            actionMap.put(WindowResult.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
               windowTitle = "Access denied";
               contentChars = "Access denied";
               responseProps = new Properties();
  @@ -616,8 +615,8 @@
            }
            if (SHOW.equals(cfg.getProperty(WINDOW_NOT_FOUND)))
            {
  -            actionMap.put(Actionable.MODES_KEY, Collections.EMPTY_LIST);
  -            actionMap.put(Actionable.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
  +            actionMap.put(WindowResult.MODES_KEY, Collections.EMPTY_LIST);
  +            actionMap.put(WindowResult.WINDOWSTATES_KEY, Collections.EMPTY_LIST);
               windowTitle = "Cannot render";
               contentChars = "Object not found " + e.getRef();
               responseProps = new Properties();
  @@ -687,8 +686,7 @@
            WindowResult.Action action = new WindowResult.Action(windowState, url, !disabled);
            windowStates.add(action);
         }
  -      Collections.sort(windowStates);
  -      actionMap.put(Actionable.WINDOWSTATES_KEY, windowStates);
  +      actionMap.put(WindowResult.WINDOWSTATES_KEY, windowStates);
      }
   
      /**
  @@ -710,8 +708,7 @@
            WindowResult.Action action = new WindowResult.Action(mode, url, !disabled);
            modes.add(action);
         }
  -      Collections.sort(modes);
  -      actionMap.put(Actionable.MODES_KEY, modes);
  +      actionMap.put(WindowResult.MODES_KEY, modes);
      }
   
   /*
  
  
  



More information about the jboss-cvs-commits mailing list