portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vku...@apache.org
Subject svn commit: r776012 - /portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java
Date Mon, 18 May 2009 17:07:32 GMT
Author: vkumar
Date: Mon May 18 17:07:32 2009
New Revision: 776012

URL: http://svn.apache.org/viewvc?rev=776012&view=rev
Log:
Fixing JS2-1016
Checking if Maximize window is layout itself

https://issues.apache.org/jira/browse/JS2-1016

Modified:
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java?rev=776012&r1=776011&r2=776012&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java
(original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/aggregator/impl/BaseAggregatorImpl.java
Mon May 18 17:07:32 2009
@@ -81,7 +81,17 @@
     protected void renderMaximizedWindow( RequestContext context, ContentPage page, ContentFragment
layoutContentFragment, 
                                           PortletWindow window )
     {
-        PortletWindow layoutWindow = context.getPortletWindow(layoutContentFragment);
+        boolean maxedLayout = false;
+        PortletWindow layoutWindow;
+        if (window.getFragment().getId().equals(layoutContentFragment.getId()))
+        {
+            layoutWindow = window;
+            maxedLayout = true;
+        }
+        else
+        {
+            layoutWindow = context.getPortletWindow(layoutContentFragment);
+        }
         
         layoutWindow.setAttribute(PortalReservedParameters.MAXIMIZED_FRAGMENT_ATTRIBUTE,
window.getFragment());
         layoutWindow.setAttribute(PortalReservedParameters.MAXIMIZED_LAYOUT_ATTRIBUTE, page.getRootContentFragment());
@@ -89,7 +99,10 @@
         try
         {
             renderer.renderNow(window.getFragment(), context);
-            renderer.renderNow(layoutContentFragment, context);
+            if (!maxedLayout)
+            {
+                renderer.renderNow(layoutContentFragment, context);
+            }
         }
         catch (Exception e)
         {



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message