portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject svn commit: r389214 - in /portals/jetspeed-2/trunk/src/webapp: desktop-themes/blue/blue.jsp desktop-themes/blue/blue.vm javascript/jetspeed/jetspeed-ajax-api.js
Date Mon, 27 Mar 2006 18:06:57 GMT
Author: taylor
Date: Mon Mar 27 10:06:56 2006
New Revision: 389214

URL: http://svn.apache.org/viewcvs?rev=389214&view=rev
Log:
current form parameters

Modified:
    portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.jsp
    portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.vm
    portals/jetspeed-2/trunk/src/webapp/javascript/jetspeed/jetspeed-ajax-api.js

Modified: portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.jsp
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.jsp?rev=389214&r1=389213&r2=389214&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.jsp (original)
+++ portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.jsp Mon Mar 27 10:06:56 2006
@@ -30,9 +30,9 @@
 	{
         jetspeed.doRender(url,portletEntityId);
 	}
-    function doAction(url, portletEntityId)
+    function doAction(url, portletEntityId, currentForm)
     {
-        jetspeed.doAction(url,portletEntityId);
+        jetspeed.doAction(url,portletEntityId, currentForm);
     }	    
 </script>
 <!-- 

Modified: portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.vm
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.vm?rev=389214&r1=389213&r2=389214&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.vm (original)
+++ portals/jetspeed-2/trunk/src/webapp/desktop-themes/blue/blue.vm Mon Mar 27 10:06:56 2006
@@ -25,9 +25,9 @@
 	    {
             jetspeed.doRender(url,portletEntityId);
     	}
-		    function doAction(url, portletEntityId)
+		    function doAction(url, portletEntityId, currentForm)
 		    {
-		            jetspeed.doAction(url,portletEntityId);
+		            jetspeed.doAction(url,portletEntityId, currentForm);
 		    }
 </script>
 <!-- 

Modified: portals/jetspeed-2/trunk/src/webapp/javascript/jetspeed/jetspeed-ajax-api.js
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/src/webapp/javascript/jetspeed/jetspeed-ajax-api.js?rev=389214&r1=389213&r2=389214&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/src/webapp/javascript/jetspeed/jetspeed-ajax-api.js (original)
+++ portals/jetspeed-2/trunk/src/webapp/javascript/jetspeed/jetspeed-ajax-api.js Mon Mar 27
10:06:56 2006
@@ -67,6 +67,7 @@
 //jetspeed.debugPortletEntityIdFilter = [ "dp-18" ]; // NOTE: uncomment causes only the listed
portlets to be loaded; all others are ignored; for testing
 jetspeed.debugPortletWindowIcons = [ "text-x-generic.png", "text-html.png", "application-x-executable.png"
];
 jetspeed.debugPortletWindowThemes = [ "theme1", "theme2" ];
+jetspeed.debugPortletDumpRawContent = [ "dp-7" ];
 
 jetspeed.testLoadPageCreateWidgetPortlets = function()
 {
@@ -78,6 +79,7 @@
 {
     if ( portlets )
     {
+        var createdPortlets = [];
         for (var portletIndex in portlets)
         {
             var portlet = portlets[portletIndex];
@@ -87,8 +89,13 @@
                     portlet = null;
             }
             if (portlet)
-                portlet.createPortletWindow(portletWindowFactory);
+            {
+                createdPortlets.push(portlet);
+                portlet.createPortletWindow(portletWindowFactory,null,true);
+            }
         }
+        for (var i = 0; i < createdPortlets.length; i++)
+            createdPortlets[i].retrievePortletContent();
     }
 }
 
@@ -99,19 +106,19 @@
     var targetPortlet = jetspeed.page.getPortlet( portletEntityId );
     if ( targetPortlet )
     {
-        //dojo.debug( "render " + portletEntityId + " url: " + url );
+        dojo.debug( "render " + portletEntityId + " url: " + url );
         targetPortlet.retrievePortletContent(null,url);
     }
 }
 
 // ... jetspeed.doAction
-jetspeed.doAction = function(url,portletEntityId)
+jetspeed.doAction = function(url,portletEntityId,currentForm)
 {
     var targetPortlet = jetspeed.page.getPortlet( portletEntityId );
     if ( targetPortlet )
     {
         dojo.debug( "action " + portletEntityId + " url: " + url );
-        //targetPortlet.retrievePortletContent(null,url);
+        targetPortlet.retrievePortletContent(new jetspeed.om.PortletActionContentListener(),
url);
     }
 }
 
@@ -282,6 +289,23 @@
     }
 }
 
+// ... jetspeed.om.PortletContentListener
+jetspeed.om.PortletActionContentListener = function()
+{
+}
+jetspeed.om.PortletActionContentListener.prototype =
+{
+    notifySuccess: function( /* String */ portletContent, /* Portlet */ portlet )
+    {
+        dojo.debug( "PortletActionContentListener: " + portletContent ) ;
+    },
+    notifyFailure: function( /* String */ type, /* String */ error, /* Portlet */ portlet
)
+    {
+        alert( "PortletActionContentListener notifyFailure type=" + type ) ;
+        dojo.debugShallow( error );
+    }
+}
+
 
 // ... jetspeed.om.PortletWidgetWindowFactory
 jetspeed.om.PortletWidgetWindowFactory = function()
@@ -318,7 +342,7 @@
     windowFactory: null,
     windowObj: null,
 
-    createPortletWindow: function(portletWindowFactory, portletContentListener)
+    createPortletWindow: function(portletWindowFactory, portletContentListener, doNotRetrieveContent)
     {
         if ( portletWindowFactory == null )
             portletWindowFactory = new jetspeed.om.PortletWidgetWindowFactory() ;
@@ -326,7 +350,8 @@
         this.windowFactory = portletWindowFactory ;
         this.windowObj = portletWindowFactory.create( this ) ;
 
-        this.retrievePortletContent(portletContentListener) ;
+        if (! doNotRetrieveContent)
+            this.retrievePortletContent(portletContentListener) ;
     },
 
     getPortletUrl: function(renderUrl)
@@ -353,8 +378,11 @@
                 //dojo.debug( "  evt:" );
                 //dojo.debugShallow( evt ) ;
 
-                //if ( portlet.entityId == "dp-18" || portlet.entityId == "dp-7" )
-                //    dojo.debug( "content: " + data);
+                if ( jetspeed.debugPortletDumpRawContent )
+                {
+                    if (dojo.lang.inArray(jetspeed.debugPortletDumpRawContent, portlet.entityId))
+                        dojo.debug( portlet.entityId + " content: " + data);  
+                }
                 if ( portletContentListener && dojo.lang.isFunction( portletContentListener.notifySuccess
) )
                 {
                     portletContentListener.notifySuccess(data, portlet);
@@ -491,7 +519,11 @@
 jetspeed.ui.PortletWidgetWindow.prototype.titleMouseOver = function(evt)
 {
     var self = this ;
-    this.titleMouseIn++ ;
+    this.titleMouseIn = 1 ;   // was ++
+    if ( djConfig.isDebug )
+    {
+        //dojo.debug( "mouseover (" + this.titleMouseIn +"): " + evt.currentTarget.className
);
+    }
     if ( this.titleMouseIn == 1 )
     {
         window.setTimeout( function() { if ( self.titleMouseIn > 0 ) { self.titleLight(
self ); self.titleMouseIn = 0; } }, 270 ) ;
@@ -516,13 +548,8 @@
 {
     var tbiWidget = dojo.widget.byId(this.widgetId + "_tbi");
 
-    //var left = dojo.style.totalOffsetLeft(tbiWidget.domNode);
-    //var top = dojo.style.totalOffsetTop(tbiWidget.domNode) - 100;
-    //dojo.debug( "minimizeWindow: " + this.domNode.id + "  move-to-left: " + left + " move-to-top:
" + top ) ;
-    //var widgetToHide = this ;
-    //dojo.fx.html.slideTo( this.domNode, 300, [ left, top ], function() { dojo.fx.html.wipeOut(widgetToHide.domNode,
400); } ) ;
     if ( tbiWidget && tbiWidget.domNode )
-        dojo.fx.html.implode( this.domNode, tbiWidget.domNode, 550 ) ; // began as 300 in
ff
+        dojo.fx.html.implode( this.domNode, tbiWidget.domNode, 340 ) ; // began as 300 in
ff
     else
         this.hide();
     
@@ -564,9 +591,13 @@
 {
     var self = this ;
     var nTitleMouseIn = this.titleMouseIn ;
+    if ( djConfig.isDebug )
+    {
+        //dojo.debug( "mouseout (" + this.titleMouseIn +"): " + evt.currentTarget.className
);
+    }
     if ( nTitleMouseIn > 0 )
     {
-        nTitleMouseIn = Math.max( 0, ( nTitleMouseIn - 1 ) );
+        nTitleMouseIn = 0 ; // was Math.max( 0, ( nTitleMouseIn - 1 ) );
         this.titleMouseIn = nTitleMouseIn ;
     }
     if ( nTitleMouseIn == 0 && this.titleLit )



---------------------------------------------------------------------
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