Author: julien(a)jboss.com
Date: 2007-11-18 18:19:13 -0500 (Sun, 18 Nov 2007)
New Revision: 9016
Modified:
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/MainProcessor.java
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/content/PresentationContentRendererContext.java
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/impl/model/UIWindowImpl.java
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/model/UIWindow.java
Log:
started portlet container integration
Modified:
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/MainProcessor.java
===================================================================
---
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/MainProcessor.java 2007-11-18
23:03:54 UTC (rev 9015)
+++
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/MainProcessor.java 2007-11-18
23:19:13 UTC (rev 9016)
@@ -43,6 +43,7 @@
import org.jboss.portal.core.model.portal.PortalObjectPath;
import org.jboss.portal.core.model.portal.Window;
import org.jboss.portal.portlet.impl.PortletRequestDecoder;
+import org.jboss.portal.portlet.StateString;
import org.jboss.portal.WindowState;
import org.jboss.portal.Mode;
@@ -138,7 +139,7 @@
}
else if (serverAction instanceof LinkActivation)
{
- GetActivation getActivation = (GetActivation)serverAction;
+ LinkActivation getActivation = (LinkActivation)serverAction;
String id = getActivation.getTargetId();
PortalObjectId poid = PortalObjectId.parse(id,
PortalObjectPath.CANONICAL_FORMAT);
Window target = (Window)portalObjectContainer.getObject(poid);
@@ -152,7 +153,10 @@
switch(decoder.getType())
{
case PortletRequestDecoder.ACTION_TYPE:
- System.out.println("Todo call portlet action");
+
+ System.out.println("TODO implement process action");
+
+
break;
case PortletRequestDecoder.NAV_TYPE:
case PortletRequestDecoder.RENDER_TYPE:
@@ -172,7 +176,10 @@
}
// Update parameters
+ StateString contentState = decoder.getNavigationalState();
+ window.setContentState(contentState);
+ //
break;
}
Modified:
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/content/PresentationContentRendererContext.java
===================================================================
---
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/content/PresentationContentRendererContext.java 2007-11-18
23:03:54 UTC (rev 9015)
+++
branches/UIServer/core-uiserver/src/main/org/jboss/portal/core/presentation/server/content/PresentationContentRendererContext.java 2007-11-18
23:19:13 UTC (rev 9016)
@@ -36,6 +36,7 @@
import org.jboss.portal.Mode;
import org.jboss.portal.WindowState;
import org.jboss.portal.portlet.invocation.RenderInvocation;
+import org.jboss.portal.portlet.StateString;
import org.jboss.portal.identity.User;
/**
@@ -81,14 +82,17 @@
windowState = WindowState.NORMAL;
}
+ StateString contentState = (StateString)uiwindow.getContentState();
+
//
- return new WindowNavigationalState(windowState, mode, null);
+ return new WindowNavigationalState(windowState, mode, contentState);
}
public void setNavigationalState(WindowNavigationalState navigationalState)
{
uiwindow.setWindowState(navigationalState.getWindowState());
uiwindow.setMode(navigationalState.getMode());
+ uiwindow.setContentState(navigationalState.getContentState());
}
public User getUser()
Modified:
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/impl/model/UIWindowImpl.java
===================================================================
---
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/impl/model/UIWindowImpl.java 2007-11-18
23:03:54 UTC (rev 9015)
+++
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/impl/model/UIWindowImpl.java 2007-11-18
23:19:13 UTC (rev 9016)
@@ -35,19 +35,17 @@
*/
public class UIWindowImpl extends UIObjectImpl implements UIWindow
{
- /**
- *
- */
+
+ /** . */
private Mode mode = null;
- /**
- *
- */
+ /** . */
private WindowState windowState = null;
- /**
- *
- */
+ /** . */
+ private Object contentState = null;
+
+ /** . */
private WindowContent content = null;
public UIWindowImpl(UIContextImpl context, String id, ObjectState state)
@@ -95,6 +93,7 @@
public void setMode(Mode mode)
{
this.mode = mode;
+ this.content = null;
}
/**
@@ -103,8 +102,20 @@
public void setWindowState(WindowState windowState)
{
this.windowState = windowState;
- }
+ this.content = null;
+ }
+ public Object getContentState()
+ {
+ return contentState;
+ }
+
+ public void setContentState(Object contentState)
+ {
+ this.contentState = contentState;
+ this.content = null;
+ }
+
/**
*
* @param <T>
Modified:
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/model/UIWindow.java
===================================================================
---
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/model/UIWindow.java 2007-11-18
23:03:54 UTC (rev 9015)
+++
branches/UIServer/uiserver/src/main/org/jboss/portal/presentation/model/UIWindow.java 2007-11-18
23:19:13 UTC (rev 9016)
@@ -54,4 +54,8 @@
* @param mode
*/
public void setMode(Mode mode);
+
+ public Object getContentState();
+
+ void setContentState(Object contentState);
}
Show replies by date