portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smi...@apache.org
Subject svn commit: r583999 [4/5] - in /portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed: ./ desktop/ widget/
Date Fri, 12 Oct 2007 00:36:48 GMT
Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.js?rev=583999&r1=583998&r2=583999&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.js
(original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.js
Thu Oct 11 17:36:47 2007
@@ -7,206 +7,248 @@
 if(!jetspeed.om){
 jetspeed.om={};
 }
-jetspeed.debug={pageLoad:false,retrievePsml:false,setPortletContent:false,doRenderDoAction:false,postParseAnnotateHtml:false,postParseAnnotateHtmlDisableAnchors:false,confirmOnSubmit:false,createWindow:false,initWinState:false,submitWinState:false,ajaxPageNav:false,dragWindow:false,profile:true,windowDecorationRandom:false,debugInPortletWindow:true,debugContainerId:(djConfig.debugContainerId?djConfig.debugContainerId:dojo.hostenv.defaultDebugContainerId)};
+jetspeed.debug={pageLoad:false,retrievePsml:false,setPortletContent:false,doRenderDoAction:false,postParseAnnotateHtml:false,postParseAnnotateHtmlDisableAnchors:false,confirmOnSubmit:false,createWindow:false,initWinState:false,submitWinState:false,ajaxPageNav:false,dragWindow:false,dragWindowStart:false,profile:true,windowDecorationRandom:false,debugInPortletWindow:true,debugContainerId:(djConfig.debugContainerId?djConfig.debugContainerId:dojo.hostenv.defaultDebugContainerId)};
+jetspeed.debugAlert=function(_1){
+if(_1){
+alert(_1);
+}
+};
 jetspeed.debugWindowLoad=function(){
-var _1=jetspeed;
-var _2=_1.id;
-var _3=dojo;
-if(djConfig.isDebug&&_1.debug.debugInPortletWindow&&_3.byId(_1.debug.debugContainerId)==null){
-var _4=_1.debugWindowReadCookie(true);
+var _2=jetspeed;
+var _3=_2.id;
+var _4=dojo;
+if(djConfig.isDebug&&_2.debug.debugInPortletWindow&&_4.byId(_2.debug.debugContainerId)==null){
+var _5=_2.debugWindowReadCookie(true);
 var wP={};
-var _6=_2.PW_ID_PREFIX+_2.DEBUG_WINDOW_TAG;
-wP[_2.PP_WINDOW_POSITION_STATIC]=false;
-wP[_2.PP_WINDOW_HEIGHT_TO_FIT]=false;
-wP[_2.PP_WINDOW_DECORATION]=_1.prefs.windowDecoration;
-wP[_2.PP_WINDOW_TITLE]="Dojo Debug";
-wP[_2.PP_WINDOW_ICON]="text-x-script.png";
-wP[_2.PP_WIDGET_ID]=_6;
-wP[_2.PP_WIDTH]=_4.width;
-wP[_2.PP_HEIGHT]=_4.height;
-wP[_2.PP_LEFT]=_4.left;
-wP[_2.PP_TOP]=_4.top;
-wP[_2.PP_EXCLUDE_PCONTENT]=false;
-wP[_2.PP_CONTENT_RETRIEVER]=new _1.om.DojoDebugContentRetriever();
-wP[_2.PP_WINDOW_STATE]=_4.windowState;
-var _7=_1.widget.PortletWindow.prototype.altInitParamsDef(null,wP);
-_1.ui.createPortletWindow(_7,null,_1);
-_7.retrieveContent(null,null);
-var _8=_1.page.getPWin(_6);
-_3.event.connect("after",_3.hostenv,"println",_8,"contentChanged");
-_3.event.connect(_8,"windowActionButtonSync",_1,"debugWindowSave");
-_3.event.connect(_8,"endSizing",_1,"debugWindowSave");
-_3.event.connect(_8,"endDragging",_1,"debugWindowSave");
-}
-};
-jetspeed.debugWindowReadCookie=function(_9){
-var _a={};
-if(_9){
-_a={width:"400",height:"400",left:"320",top:"0",windowState:jetspeed.id.ACT_MINIMIZE};
-}
-var _b=dojo.io.cookie.getCookie(jetspeed.id.DEBUG_WINDOW_TAG);
-if(_b!=null&&_b.length>0){
-var _c=_b.split("|");
-if(_c&&_c.length>=4){
-_a.width=_c[0];
-_a.height=_c[1];
-_a.top=_c[2];
-_a.left=_c[3];
-if(_c.length>4&&_c[4]!=null&&_c[4].length>0){
-_a.windowState=_c[4];
+var _7=_3.PW_ID_PREFIX+_3.DEBUG_WINDOW_TAG;
+wP[_3.PP_WINDOW_POSITION_STATIC]=false;
+wP[_3.PP_WINDOW_HEIGHT_TO_FIT]=false;
+wP[_3.PP_WINDOW_DECORATION]=_2.prefs.windowDecoration;
+wP[_3.PP_WINDOW_TITLE]="Dojo Debug";
+wP[_3.PP_WINDOW_ICON]="text-x-script.png";
+wP[_3.PP_WIDGET_ID]=_7;
+wP[_3.PP_WIDTH]=_5.width;
+wP[_3.PP_HEIGHT]=_5.height;
+wP[_3.PP_LEFT]=_5.left;
+wP[_3.PP_TOP]=_5.top;
+wP[_3.PP_EXCLUDE_PCONTENT]=false;
+wP[_3.PP_CONTENT_RETRIEVER]=new _2.om.DojoDebugContentRetriever();
+wP[_3.PP_WINDOW_STATE]=_5.windowState;
+if(_5.windowState==_3.ACT_MAXIMIZE){
+_2.page.maximizedOnInit=_7;
+}
+var _8=_2.widget.PortletWindow.prototype.altInitParamsDef(null,wP);
+_2.ui.createPortletWindow(_8,null,_2);
+_8.retrieveContent(null,null);
+var _9=_2.page.getPWin(_7);
+_4.event.connect("after",_4.hostenv,"println",_9,"contentChanged");
+_4.event.connect(_9,"actionBtnSync",_2,"debugWindowSave");
+_4.event.connect(_9,"endSizing",_2,"debugWindowSave");
+_4.event.connect(_9,"endDragging",_2,"debugWindowSave");
+}
+};
+jetspeed.debugWindowReadCookie=function(_a){
+var _b={};
+if(_a){
+_b={width:"400",height:"400",left:"320",top:"0",windowState:jetspeed.id.ACT_MINIMIZE};
+}
+var _c=dojo.io.cookie.getCookie(jetspeed.id.DEBUG_WINDOW_TAG);
+if(_c!=null&&_c.length>0){
+var _d=_c.split("|");
+if(_d&&_d.length>=4){
+_b.width=_d[0];
+_b.height=_d[1];
+_b.top=_d[2];
+_b.left=_d[3];
+if(_d.length>4&&_d[4]!=null&&_d[4].length>0){
+_b.windowState=_d[4];
 }
 }
 }
-return _a;
+return _b;
 };
 jetspeed.debugWindowRestore=function(){
-var _d=jetspeed.debugWindow();
-if(!_d){
+var _e=jetspeed.debugWindow();
+if(!_e){
 return;
 }
-_d.restoreWindow();
+_e.restoreWindow();
 };
 jetspeed.debugWindow=function(){
-var _e=jetspeed.id.PW_ID_PREFIX+jetspeed.id.DEBUG_WINDOW_TAG;
-return jetspeed.page.getPWin(_e);
+var _f=jetspeed.id.PW_ID_PREFIX+jetspeed.id.DEBUG_WINDOW_TAG;
+return jetspeed.page.getPWin(_f);
 };
 jetspeed.debugWindowId=function(){
 return jetspeed.id.PW_ID_PREFIX+jetspeed.id.DEBUG_WINDOW_TAG;
 };
 jetspeed.debugWindowSave=function(){
-var _f=jetspeed.debugWindow();
-if(!_f){
+var _10=jetspeed.debugWindow();
+if(!_10){
 return null;
 }
-if(!_f.posStatic){
-var _10=_f.getCurWinStateForPersist(false);
-var _11=_10.width;
-var _12=_10.height;
-var _13=_10.top;
-var _14=_10.left;
-if(_f.windowState==jetspeed.id.ACT_MINIMIZE){
-var _15=_f.getDimsObj(_f.posStatic);
-if(_15!=null){
-if(_15.height!=null&&_15.height>0){
-_12=_15.height;
-}
-}else{
-var _16=jetspeed.debugWindowReadCookie(false);
-if(_16.height!=null&&_16.height>0){
-_12=_16.height;
-}
+if(!_10.posStatic){
+var _11=_10.getCurWinStateForPersist(false);
+var _12=_11.width,_13=_11.height,_14=_11.top,_15=_11.left;
+var _16=_10.windowState;
+if(!_16){
+_16=jetspeed.id.ACT_RESTORE;
 }
-}
-var _17=_11+"|"+_12+"|"+_13+"|"+_14+"|"+_f.windowState;
+var _17=_12+"|"+_13+"|"+_14+"|"+_15+"|"+_16;
 dojo.io.cookie.setCookie(jetspeed.id.DEBUG_WINDOW_TAG,_17,30,"/");
+var _18=dojo.io.cookie.getCookie(jetspeed.id.DEBUG_WINDOW_TAG);
 }
 };
-jetspeed.debugDumpForm=function(_18){
-if(!_18){
+jetspeed.debugDumpForm=function(_19){
+if(!_19){
 return null;
 }
-var _19=_18.toString();
-if(_18.name){
-_19+=" name="+_18.name;
-}
-if(_18.id){
-_19+=" id="+_18.id;
-}
-var _1a=dojo.io.encodeForm(_18);
-_19+=" data="+_1a;
-return _19;
+var _1a=_19.toString();
+if(_19.name){
+_1a+=" name="+_19.name;
+}
+if(_19.id){
+_1a+=" id="+_19.id;
+}
+var _1b=dojo.io.encodeForm(_19);
+_1a+=" data="+_1b;
+return _1a;
 };
 jetspeed.om.DojoDebugContentRetriever=function(){
 this.initialized=false;
 };
-jetspeed.om.DojoDebugContentRetriever.prototype={getContent:function(_1b,_1c,_1d,_1e){
-if(!_1b){
-_1b={};
+jetspeed.om.DojoDebugContentRetriever.prototype={getContent:function(_1c,_1d,_1e,_1f){
+if(!_1c){
+_1c={};
 }
 if(!this.initialized){
-var _1f=jetspeed;
-var _20="";
-var _21=_1f.debug.debugContainerId;
-var _22=_1f.debugWindow();
-if(_1f.altDebugWindowContent){
-_20=_1f.altDebugWindowContent();
+var _20=jetspeed;
+var _21="";
+var _22=_20.debug.debugContainerId;
+var _23=_20.debugWindow();
+if(_20.altDebugWindowContent){
+_21=_20.altDebugWindowContent();
 }else{
-_20+="<div id=\""+_21+"\"></div>";
+_21+="<div id=\""+_22+"\"></div>";
 }
-if(_1c){
-_1c.notifySuccess(_20,_1b.url,_1d);
+if(_1d){
+_1d.notifySuccess(_21,_1c.url,_1e);
 }else{
-if(_22){
-_22.setPortletContent(_20,_1b.url);
+if(_23){
+_23.setPortletContent(_21,_1c.url);
 }
 }
 this.initialized=true;
-if(_22){
-var _23="javascript: void(document.getElementById('"+_21+"').innerHTML='')";
-var _24="";
+if(_23){
+var _24="javascript: void(document.getElementById('"+_22+"').innerHTML='')";
+var _25="";
 for(var i=0;i<20;i++){
-_24+="&nbsp;";
+_25+="&nbsp;";
 }
-var _26=_22.title+_24+"<a href=\""+_23+"\"><span style=\"font-size: xx-small; font-weight:
normal\">Clear</span></a>";
-_22.tbTextNode.innerHTML=_26;
+var _27=_23.title+_25+"<a href=\""+_24+"\"><span style=\"font-size: xx-small; font-weight:
normal\">Clear</span></a>";
+_23.tbTextNode.innerHTML=_27;
 }
 }
 }};
 jetspeed.debugDumpColWidths=function(){
 for(var i=0;i<jetspeed.page.columns.length;i++){
-var _28=jetspeed.page.columns[i];
-dojo.debug("jetspeed.page.columns["+i+"] outer-width: "+dojo.html.getMarginBox(_28.domNode).width);
+var _29=jetspeed.page.columns[i];
+dojo.debug("jetspeed.page.columns["+i+"] outer-width: "+dojo.html.getMarginBox(_29.domNode).width);
 }
 };
 jetspeed.debugDumpWindowsPerCol=function(){
 for(var i=0;i<jetspeed.page.columns.length;i++){
-var _2a=jetspeed.page.columns[i];
-var _2b=jetspeed.ui.getPWinChildren(_2a.domNode,null);
-var _2c=jetspeed.ui.getPWinsFromNodes(_2b.portletWindowNodes);
-var _2d={dumpMsg:""};
-if(_2c!=null){
-dojo.lang.forEach(_2c,function(_2e){
-_2d.dumpMsg=_2d.dumpMsg+(_2d.dumpMsg.length>0?", ":"")+_2e.portlet.entityId;
+var _2b=jetspeed.page.columns[i];
+var _2c=jetspeed.ui.getPWinAndColChildren(_2b.domNode,null);
+var _2d=jetspeed.ui.getPWinsFromNodes(_2c.matchingNodes);
+var _2e={dumpMsg:""};
+if(_2d!=null){
+dojo.lang.forEach(_2d,function(_2f){
+_2e.dumpMsg=_2e.dumpMsg+(_2e.dumpMsg.length>0?", ":"")+_2f.portlet.entityId;
 });
 }
-_2d.dumpMsg="column "+i+": "+_2d.dumpMsg;
-dojo.debug(_2d.dumpMsg);
+_2e.dumpMsg="column "+i+": "+_2e.dumpMsg;
+dojo.debug(_2e.dumpMsg);
 }
 };
 jetspeed.debugDumpWindows=function(){
-var _2f=jetspeed.page.getPWins();
-var _30="";
-for(var i=0;i<_2f.length;i++){
+var _30=jetspeed.page.getPWins();
+var _31="";
+for(var i=0;i<_30.length;i++){
 if(i>0){
-_30+=", ";
+_31+=", ";
 }
-_30+=_2f[i].widgetId;
+_31+=_30[i].widgetId;
 }
-dojo.debug("PortletWindows: "+_30);
+dojo.debug("PortletWindows: "+_31);
 };
 jetspeed.debugLayoutInfo=function(){
-var _32=jetspeed.page;
-var _33="";
+var _33=jetspeed.page;
+var _34="";
 var i=0;
-for(var _35 in _32.layouts){
+for(var _36 in _33.layouts){
 if(i>0){
-_33+="\r\n";
+_34+="\r\n";
 }
-_33+="layout["+_35+"]: "+jetspeed.printobj(_32.layouts[_35],true,true,true);
+_34+="layout["+_36+"]: "+jetspeed.printobj(_33.layouts[_36],true,true,true);
 i++;
 }
-return _33;
+return _34;
 };
-jetspeed.debugColumnInfo=function(){
-var _36=jetspeed.page;
-var _37="";
-for(var i=0;i<_36.columns.length;i++){
-if(i>0){
-_37+="\r\n";
+jetspeed.debugColumns=function(_37,_38){
+var _39=jetspeed;
+var _3a=_39.page;
+var _3b=(!_38);
+var _3c=_3a.columns,col;
+if(!_3c){
+return null;
+}
+var _3e=dojo.byId(_39.id.COLUMNS);
+var _3f="";
+var _40=!_37;
+return _39._debugColumnTree(_3b,_3e,_3f,"\r\n",_39.debugindentT,_40,_39,_3a);
+};
+jetspeed._debugColumnTree=function(_41,_42,_43,_44,_45,_46,_47,_48){
+var _49=_47.ui.getPWinAndColChildren(_42,null,false,true,true,_46);
+var _4a=_49.matchingNodes;
+if(!_4a||_4a.length==0){
+return _43;
+}
+var _4b,col,_4d,_4e,_4f=(_44+_45);
+for(var i=0;i<_4a.length;i++){
+_4b=_4a[i];
+col=_48.getColFromColNode(_4b);
+_4d=null;
+if(!col){
+_4d=_48.getPWinFromNode(_4b);
+}
+_43+=_44;
+if(col){
+_43+=_47.debugColumn(col,_41);
+_43=_47._debugColumnTree(_41,_4b,_43,_4f,_45,_46,_47,_48);
+}else{
+if(_4d){
+_4e=_4d.title;
+_43+=_4d.widgetId+((_4e&&_4e.length>0)?(" - "+_4e):"");
+}else{
+_43+=_47.debugNode(_4b);
+}
+}
+}
+return _43;
+};
+jetspeed.debugColumn=function(col,_52){
+if(!col){
+return null;
 }
-_37+=_36.columns[i].toString();
+var _53=col.domNode;
+var out="column["+dojo.string.padLeft(String(col.pageColumnIndex),2," ")+"]";
+out+=" colContainer="+(col.columnContainer?"T":"F")+" layoutHeader="+(col.layoutHeader?"T":"F")+"
id="+(_53!=null?_53.id:"null")+" layoutCol="+col.layoutColumnIndex+" layoutId="+col.layoutId+"
size="+col.size;
+if(_53!=null&&!_52){
+var _55=dojo.html.getAbsolutePosition(_53,true);
+var _56=dojo.html.getMarginBox(_53);
+out+=" dims={"+"left:"+(_55.x)+", right:"+(_55.x+_56.width)+", top:"+(_55.y)+", bottom:"+(_55.y+_56.height)+"}";
 }
-return _37;
+return out;
 };
 jetspeed.debugSavedWinState=function(){
 return jetspeed.debugWinStateAll(true);
@@ -215,68 +257,173 @@
 return jetspeed.debugWinStateAll(false);
 };
 jetspeed.debugPortletActions=function(){
-var _39=jetspeed.page.getPortletArray();
-var _3a="";
-for(var i=0;i<_39.length;i++){
-var _3c=_39[i];
+var _57=jetspeed.page.getPortletArray();
+var _58="";
+for(var i=0;i<_57.length;i++){
+var _5a=_57[i];
 if(i>0){
-_3a+="\r\n";
+_58+="\r\n";
 }
-_3a+="portlet ["+_3c.name+"] actions: {";
-for(var _3d in _3c.actions){
-_3a+=_3d+"={"+jetspeed.printobj(_3c.actions[_3d],true)+"} ";
+_58+="portlet ["+_5a.name+"] actions: {";
+for(var _5b in _5a.actions){
+_58+=_5b+"={"+jetspeed.printobj(_5a.actions[_5b],true)+"} ";
 }
-_3a+="}";
+_58+="}";
 }
-return _3a;
+return _58;
 };
-jetspeed.debugWinStateAll=function(_3e){
-var _3f=jetspeed.page.getPortletArray();
-var _40="";
-for(var i=0;i<_3f.length;i++){
-var _42=_3f[i];
+jetspeed.debugWinStateAll=function(_5c){
+var _5d=jetspeed.page.getPortletArray();
+var _5e="";
+for(var i=0;i<_5d.length;i++){
+var _60=_5d[i];
 if(i>0){
-_40+="\r\n";
+_5e+="\r\n";
 }
-var _43=null;
+var _61=null;
 try{
-if(_3e){
-_43=_42.getSavedWinState();
+if(_5c){
+_61=_60.getSavedWinState();
 }else{
-_43=_42.getCurWinState();
+_61=_60.getCurWinState();
 }
 }
 catch(e){
 }
-_40+="["+_42.name+"] "+((_43==null)?"null":jetspeed.printobj(_43,true));
+_5e+="["+_60.name+"] "+((_61==null)?"null":jetspeed.printobj(_61,true));
 }
-return _40;
+return _5e;
+};
+jetspeed.debugPWinPos=function(_62){
+var _63=jetspeed;
+var _64=dojo;
+var _65=_63.UAie;
+var djH=_64.html;
+var _67=_62.domNode;
+var _68=_62.containerNode;
+var _69=_62.tbNode;
+var _6a=_62.rbNode;
+var _6b=djH.getAbsolutePosition(_67,true);
+var _6c=djH.getAbsolutePosition(_68,true);
+var _6d=djH.getAbsolutePosition(_69,true);
+var _6e=djH.getAbsolutePosition(_6a,true);
+var _6f=_64.gcs(_67),_70=_64.gcs(_68),_71=_64.gcs(_69),_72=_64.gcs(_6a);
+var _73=null;
+if(_63.UAie6){
+_73=djH.getAbsolutePosition(_62.bgIframe.iframe,true);
+}
+var _74=null;
+var _75=null;
+var _76=null;
+if(_62.iframesInfo!=null&&_62.iframesInfo.iframeCover!=null){
+_74=_62.iframesInfo.iframeCover;
+_75=djH.getAbsolutePosition(_74,true);
+_76=_64.gcs(_74);
+}
+var _77=_62._getLayoutInfo();
+var ind=_63.debugindent;
+var _79=_63.debugindentH;
+_64.hostenv.println("wnd-dims ["+_62.widgetId+"  "+_62.title+"]"+"  z="+_67.style.zIndex+"
hfit="+_62.heightToFit);
+_64.hostenv.println(ind+"d.abs {x="+_6b.x+" y="+_6b.y+"}"+(_65?("  hasLayout="+_67.currentStyle.hasLayout):""));
+_64.hostenv.println(ind+"c.abs {x="+_6c.x+" y="+_6c.y+"}"+(_65?("  hasLayout="+_68.currentStyle.hasLayout):""));
+_64.hostenv.println(ind+"t.abs {x="+_6d.x+" y="+_6d.y+"}"+(_65?("  hasLayout="+_69.currentStyle.hasLayout):""));
+_64.hostenv.println(ind+"r.abs {x="+_6e.x+" y="+_6e.y+"}"+(_65?("  hasLayout="+_6a.currentStyle.hasLayout):""));
+if(_73!=null){
+_64.hostenv.println(ind+"ibg.abs {x="+_73.x+" y="+_73.y+"}"+_79+" z="+_62.bgIframe.iframe.currentStyle.zIndex+(_65?("
hasLayout="+_62.bgIframe.iframe.currentStyle.hasLayout):""));
+}
+if(_75!=null){
+_64.hostenv.println(ind+"icv.abs {x="+_75.x+" y="+_75.y+"}"+_79+" z="+_76.zIndex+(_65?("
hasLayout="+_74.currentStyle.hasLayout):""));
+}
+_64.hostenv.println(ind+"d.mb "+_63.debugDims(_64.getMarginBox(_67,_6f,_63))+_79+" d.offset
{w="+_67.offsetWidth+" h="+_67.offsetHeight+"}");
+_64.hostenv.println(ind+"d.cb "+_63.debugDims(_64.getContentBox(_67,_6f,_63))+_79+" d.client
{w="+_67.clientWidth+" h="+_67.clientHeight+"}");
+_64.hostenv.println(ind+"d.style {"+_63._debugPWinStyle(_67,_6f,"width",true)+_63._debugPWinStyle(_67,_6f,"height")+_79+_63._debugPWinStyle(_67,_6f,"left")+_63._debugPWinStyle(_67,_6f,"top")+_79+"
pos="+_6f.position.substring(0,1)+" ofx="+_6f.overflowX.substring(0,1)+" ofy="+_6f.overflowY.substring(0,1)+"}");
+_64.hostenv.println(ind+"c.mb "+_63.debugDims(_64.getMarginBox(_68,_70,_63))+_79+" c.offset
{w="+_68.offsetWidth+" h="+_68.offsetHeight+"}");
+_64.hostenv.println(ind+"c.cb "+_63.debugDims(_64.getContentBox(_68,_70,_63))+_79+" c.client
{w="+_68.clientWidth+" h="+_68.clientHeight+"}");
+_64.hostenv.println(ind+"c.style {"+_63._debugPWinStyle(_68,_70,"width",true)+_63._debugPWinStyle(_68,_70,"height")+_79+_63._debugPWinStyle(_68,_70,"left")+_63._debugPWinStyle(_68,_70,"top")+_79+"
ofx="+_70.overflowX.substring(0,1)+" ofy="+_70.overflowY.substring(0,1)+" d="+_70.display.substring(0,1)+"}");
+_64.hostenv.println(ind+"t.mb "+_63.debugDims(_64.getMarginBox(_69,_71,_63))+_79+" t.offset
{w="+_69.offsetWidth+" h="+_69.offsetHeight+"}");
+_64.hostenv.println(ind+"t.cb "+_63.debugDims(_64.getContentBox(_69,_71,_63))+_79+" t.client
{w="+_69.clientWidth+" h="+_69.clientHeight+"}");
+_64.hostenv.println(ind+"t.style {"+_63._debugPWinStyle(_69,_71,"width",true)+_63._debugPWinStyle(_69,_71,"height")+_79+_63._debugPWinStyle(_69,_71,"left")+_63._debugPWinStyle(_69,_71,"top")+"}");
+_64.hostenv.println(ind+"r.mb "+_63.debugDims(_64.getMarginBox(_6a,_72,_63))+_79+" r.offset
{w="+_6a.offsetWidth+" h="+_6a.offsetHeight+"}");
+_64.hostenv.println(ind+"r.cb "+_63.debugDims(_64.getContentBox(_6a,_72,_63))+_79+" r.client
{w="+_6a.clientWidth+" h="+_6a.clientHeight+"}");
+_64.hostenv.println(ind+"r.style {"+_63._debugPWinStyle(_6a,_72,"width",true)+_63._debugPWinStyle(_6a,_72,"height")+_79+_63._debugPWinStyle(_6a,_72,"left")+_63._debugPWinStyle(_6a,_72,"top")+"}");
+if(_73!=null){
+var _7a=_62.bgIframe.iframe;
+var _7b=_64.gcs(_7a);
+_64.hostenv.println(ind+"ibg.mb "+_63.debugDims(_64.getMarginBox(_7a,_7b,_63)));
+_64.hostenv.println(ind+"ibg.cb "+_63.debugDims(_64.getContentBox(_7a,_7b,_63)));
+_64.hostenv.println(ind+"ibg.style {"+_63._debugPWinStyle(_7a,_7b,"width",true)+_63._debugPWinStyle(_7a,_7b,"height")+_79+_63._debugPWinStyle(_7a,_7b,"left")+_63._debugPWinStyle(_7a,_7b,"top")+_79+"
pos="+_7b.position.substring(0,1)+" ofx="+_7b.overflowX.substring(0,1)+" ofy="+_7b.overflowY.substring(0,1)+"
d="+_7b.display.substring(0,1)+"}");
+}
+if(_74){
+_64.hostenv.println(ind+"icv.mb "+_63.debugDims(_64.getMarginBox(_74,_76,_63)));
+_64.hostenv.println(ind+"icv.cb "+_63.debugDims(_64.getContentBox(_74,_76,_63)));
+_64.hostenv.println(ind+"icv.style {"+_63._debugPWinStyle(_74,_76,"width",true)+_63._debugPWinStyle(_74,_76,"height")+_79+_63._debugPWinStyle(_74,_76,"left")+_63._debugPWinStyle(_74,_76,"top")+_79+"
pos="+_76.position.substring(0,1)+" ofx="+_76.overflowX.substring(0,1)+" ofy="+_76.overflowY.substring(0,1)+"
d="+_76.display.substring(0,1)+"}");
+}
+var leN=_77.dNode;
+_64.hostenv.println(ind+"dLE {"+"-w="+leN.lessW+" -h="+leN.lessH+" mw="+leN.mE.w+" mh="+leN.mE.h+"
bw="+leN.bE.w+" bh="+leN.bE.h+" pw="+leN.pE.w+" ph="+leN.pE.h+"}");
+leN=_77.cNode;
+_64.hostenv.println(ind+"cLE {"+"-w="+leN.lessW+" -h="+leN.lessH+" mw="+leN.mE.w+" mh="+leN.mE.h+"
bw="+leN.bE.w+" bh="+leN.bE.h+" pw="+leN.pE.w+" ph="+leN.pE.h+"}");
+leN=_77.tbNode;
+_64.hostenv.println(ind+"tLE {"+"-w="+leN.lessW+" -h="+leN.lessH+" mw="+leN.mE.w+" mh="+leN.mE.h+"
bw="+leN.bE.w+" bh="+leN.bE.h+" pw="+leN.pE.w+" ph="+leN.pE.h+"}");
+leN=_77.rbNode;
+_64.hostenv.println(ind+"rLE {"+"-w="+leN.lessW+" -h="+leN.lessH+" mw="+leN.mE.w+" mh="+leN.mE.h+"
bw="+leN.bE.w+" bh="+leN.bE.h+" pw="+leN.pE.w+" ph="+leN.pE.h+"}");
+_64.hostenv.println(ind+"cNode_mBh_LessBars="+_77.cNode_mBh_LessBars);
+_64.hostenv.println(ind+"dimsTiled "+_63.debugDims(_62.dimsTiled));
+_64.hostenv.println(ind+"dimsUntiled "+_63.debugDims(_62.dimsUntiled));
+if(_62.dimsTiledTemp!=null){
+_64.hostenv.println(ind+"dimsTiledTemp "+_63.debugDims(_62.dimsTiledTemp));
+}
+if(_62.dimsUntiledTemp!=null){
+_64.hostenv.println(ind+"dimsUntiledTemp="+_63.debugDims(_62.dimsUntiledTemp));
+}
+_64.hostenv.println(ind+"--------------------");
+},jetspeed.debugDims=function(box,_7e){
+return ("{w="+(box.w==undefined?(box.width==undefined?"null":box.width):box.w)+" h="+(box.h==undefined?(box.height==undefined?"null":box.height):box.h)+(box.l!=undefined?("
l="+box.l):(box.left==undefined?"":(" l="+box.left)))+(box.t!=undefined?(" t="+box.t):(box.top==undefined?"":("
t="+box.top)))+(box.right!=undefined?(" r="+box.right):"")+(box.bottom!=undefined?(" b="+box.bottom):"")+(!_7e?"}":""));
+};
+jetspeed._debugPWinStyle=function(_7f,_80,_81,_82){
+var _83=_7f.style[_81];
+var _84=_80[_81];
+if(_83=="auto"){
+_83="a";
+}
+if(_84=="auto"){
+_84="a";
+}
+var _85=null;
+if(_83==_84){
+_85=("\""+_84+"\"");
+}else{
+_85=("\""+_83+"\"/"+_84);
+}
+return ((_82?"":" ")+_81.substring(0,1)+"="+_85);
 };
 if(jetspeed.debug.profile){
-dojo.profile.clearItem=function(_44){
-return (this._profiles[_44]={iters:0,total:0});
+dojo.profile.clearItem=function(_86){
+return (this._profiles[_86]={iters:0,total:0});
 };
-dojo.profile.debugItem=function(_45,_46){
-var _47=this._profiles[_45];
-if(_47==null){
+dojo.profile.debugItem=function(_87,_88){
+var _89=this._profiles[_87];
+if(_89==null){
 return null;
 }
-if(_47.iters==0){
-return [_45," not profiled."].join("");
+if(_89.iters==0){
+return [_87," not profiled."].join("");
 }
-var _48=[_45," took ",_47.total," msec for ",_47.iters," iteration"];
-if(_47.iters>1){
-_48.push("s (",(Math.round(_47.total/_47.iters*100)/100)," msec each)");
+var _8a=[_87," took ",_89.total," msec for ",_89.iters," iteration"];
+if(_89.iters>1){
+_8a.push("s (",(Math.round(_89.total/_89.iters*100)/100)," msec each)");
 }
-dojo.debug(_48.join(""));
-if(_46){
-this.clearItem(_45);
+dojo.debug(_8a.join(""));
+if(_88){
+this.clearItem(_87);
 }
 };
-dojo.profile.debugAllItems=function(_49){
+dojo.profile.debugAllItems=function(_8b){
 for(var x=0;x<this._pns.length;x++){
-this.debugItem(this._pns[x],_49);
+this.debugItem(this._pns[x],_8b);
 }
 };
 }
+window.getPWin=function(_8d){
+return jetspeed.page.getPWin(_8d);
+};
 

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.src.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.src.js?rev=583999&r1=583998&r2=583999&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.src.js
(original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/desktop/debug.src.js
Thu Oct 11 17:36:47 2007
@@ -46,6 +46,7 @@
     submitWinState: false,
     ajaxPageNav: false,
     dragWindow: false,
+    dragWindowStart: false,
 
     profile: true,
 
@@ -65,6 +66,12 @@
 //jetspeed.debugContentDumpIds = [ "js-cp-selector.*" ];          // dump portlet selector
 
 
+jetspeed.debugAlert = function( msg )
+{
+    if ( msg )
+        alert( msg );
+};
+
 // debug window
 
 jetspeed.debugWindowLoad = function()
@@ -90,6 +97,8 @@
         wP[ jsId.PP_EXCLUDE_PCONTENT ] = false;
         wP[ jsId.PP_CONTENT_RETRIEVER ] = new jsObj.om.DojoDebugContentRetriever();
         wP[ jsId.PP_WINDOW_STATE ] = dbWSt.windowState;
+        if ( dbWSt.windowState == jsId.ACT_MAXIMIZE )
+            jsObj.page.maximizedOnInit = dbWId;
         var pwP = jsObj.widget.PortletWindow.prototype.altInitParamsDef( null, wP );
         jsObj.ui.createPortletWindow( pwP, null, jsObj );
         pwP.retrieveContent( null, null );
@@ -97,7 +106,7 @@
 
         djObj.event.connect( "after", djObj.hostenv, "println", dbWW, "contentChanged" );
     
-        djObj.event.connect( dbWW, "windowActionButtonSync", jsObj, "debugWindowSave" );
+        djObj.event.connect( dbWW, "actionBtnSync", jsObj, "debugWindowSave" );
         djObj.event.connect( dbWW, "endSizing", jsObj, "debugWindowSave" );
         djObj.event.connect( dbWW, "endDragging", jsObj, "debugWindowSave" );
     }
@@ -142,25 +151,12 @@
     if ( ! debugWindowWidget.posStatic )
     {
         var currentState = debugWindowWidget.getCurWinStateForPersist( false );
-        var cWidth = currentState.width; var cHeight = currentState.height; var cTop = currentState.top;
var cLeft = currentState.left;
-        if ( debugWindowWidget.windowState == jetspeed.id.ACT_MINIMIZE )
-        {
-            var dimsCurrent = debugWindowWidget.getDimsObj( debugWindowWidget.posStatic );
-            if ( dimsCurrent != null )
-            {
-                if ( dimsCurrent.height != null && dimsCurrent.height > 0 )
-                    cHeight = dimsCurrent.height;
-            }
-            else
-            {
-                var debugWindowState = jetspeed.debugWindowReadCookie( false );
-                if ( debugWindowState.height != null && debugWindowState.height >
0 )
-                    cHeight = debugWindowState.height;
-            }
-        }
-
-        var stateCookieVal = cWidth + "|" + cHeight + "|" + cTop + "|" + cLeft + "|" + debugWindowWidget.windowState;
+        var cWidth = currentState.width, cHeight = currentState.height, cTop = currentState.top,
cLeft = currentState.left;
+        var cWinState = debugWindowWidget.windowState;
+        if ( ! cWinState ) cWinState = jetspeed.id.ACT_RESTORE;
+        var stateCookieVal = cWidth + "|" + cHeight + "|" + cTop + "|" + cLeft + "|" + cWinState;
         dojo.io.cookie.setCookie( jetspeed.id.DEBUG_WINDOW_TAG, stateCookieVal, 30, "/" );
+        var readstateCookieVal = dojo.io.cookie.getCookie( jetspeed.id.DEBUG_WINDOW_TAG );
     }
 };
 
@@ -235,8 +231,8 @@
     for ( var i = 0 ; i < jetspeed.page.columns.length ; i++ )
     {
         var columnElmt = jetspeed.page.columns[i];
-        var windowNodesInColumn = jetspeed.ui.getPWinChildren( columnElmt.domNode, null );
-        var portletWindowsInColumn = jetspeed.ui.getPWinsFromNodes( windowNodesInColumn.portletWindowNodes
);
+        var windowNodesInColumn = jetspeed.ui.getPWinAndColChildren( columnElmt.domNode,
null );
+        var portletWindowsInColumn = jetspeed.ui.getPWinsFromNodes( windowNodesInColumn.matchingNodes
);
         var dumpClosure = { dumpMsg: "" };
         if ( portletWindowsInColumn != null )
         {
@@ -274,16 +270,63 @@
     }
     return dumpMsg;
 };
-jetspeed.debugColumnInfo = function()
+
+jetspeed.debugColumns = function( includePWins, includeDims )
 {
-    var jsPage = jetspeed.page;
-    var dumpMsg = "";
-    for ( var i = 0; i < jsPage.columns.length; i++ )
+    var jsObj = jetspeed;
+    var jsPage = jsObj.page;
+    var suppressDims = (! includeDims);
+    var allCols = jsPage.columns, col;
+    if ( ! allCols ) return null;
+    var columnContainerNode = dojo.byId( jsObj.id.COLUMNS );
+    var buff = "";
+    var exclPWins = ! includePWins;
+    return jsObj._debugColumnTree( suppressDims, columnContainerNode, buff, "\r\n", jsObj.debugindentT,
exclPWins, jsObj, jsPage );
+};
+jetspeed._debugColumnTree = function( suppressDims, parentNode, buff, indent, indentAddNextLevel,
exclPWins, jsObj, jsPage )
+{
+    var childrenResult = jsObj.ui.getPWinAndColChildren( parentNode, null, false, true, true,
exclPWins );
+    var childNodes = childrenResult.matchingNodes;
+    if ( ! childNodes || childNodes.length == 0 ) return buff;
+    var child, col, pWin, pWinTitle, nextIndent = (indent + indentAddNextLevel);
+    for ( var i = 0 ; i < childNodes.length ; i++ )
+    {
+        child = childNodes[i];
+        col = jsPage.getColFromColNode( child );
+        pWin = null;
+        if ( ! col )
+            pWin = jsPage.getPWinFromNode( child );
+        buff += indent;
+        if ( col )
+        {
+            buff += jsObj.debugColumn( col, suppressDims );
+            buff = jsObj._debugColumnTree( suppressDims, child, buff, nextIndent, indentAddNextLevel,
exclPWins, jsObj, jsPage );
+        }
+        else if ( pWin )
+        {
+            pWinTitle = pWin.title;
+            buff += pWin.widgetId + ( ( pWinTitle && pWinTitle.length > 0 ) ?
( " - " + pWinTitle ) : "" );
+        }
+        else
+        {
+            buff += jsObj.debugNode( child );
+        }
+    }
+    return buff;
+};
+jetspeed.debugColumn = function( col, suppressDims )
+{
+    if ( ! col ) return null;
+    var dNodeCol = col.domNode;
+    var out = "column[" + dojo.string.padLeft( String(col.pageColumnIndex), 2, " " ) + "]";
+    out += " colContainer=" + ( col.columnContainer ? "T" : "F" ) + " layoutHeader=" + (
col.layoutHeader ? "T" : "F" ) + " id=" + ( dNodeCol != null ? dNodeCol.id : "null" ) + "
layoutCol=" + col.layoutColumnIndex + " layoutId=" + col.layoutId + " size=" + col.size;
+    if ( dNodeCol != null && ! suppressDims )
     {
-        if ( i > 0 ) dumpMsg += "\r\n";
-        dumpMsg += jsPage.columns[i].toString();
+        var colAbsPos = dojo.html.getAbsolutePosition( dNodeCol, true );
+        var marginBox = dojo.html.getMarginBox( dNodeCol );
+        out += " dims={" + "left:" + (colAbsPos.x) + ", right:" + (colAbsPos.x + marginBox.width)
+ ", top:" + (colAbsPos.y) + ", bottom:" + (colAbsPos.y + marginBox.height) + "}";
     }
-    return dumpMsg;
+    return out;
 };
 jetspeed.debugSavedWinState = function()
 {
@@ -330,6 +373,113 @@
     return dumpMsg;
 };
 
+// Portlet Window debug info functions
+
+jetspeed.debugPWinPos = function( pWin )
+{
+    var jsObj = jetspeed;
+    var djObj = dojo;
+    var isIE = jsObj.UAie;
+    var djH = djObj.html;
+    var dNode = pWin.domNode;
+    var cNode = pWin.containerNode;
+    var tbNode = pWin.tbNode;
+    var rbNode = pWin.rbNode;
+    var dAbsPos = djH.getAbsolutePosition( dNode, true );
+    var cAbsPos = djH.getAbsolutePosition( cNode, true );
+    var tAbsPos = djH.getAbsolutePosition( tbNode, true );
+    var rAbsPos = djH.getAbsolutePosition( rbNode, true );
+    var dCompStyle = djObj.gcs( dNode ), cCompStyle = djObj.gcs( cNode ), tCompStyle = djObj.gcs(
tbNode ), rCompStyle = djObj.gcs( rbNode );
+    var bgIfrmAbsPos = null;
+    if ( jsObj.UAie6 )
+        bgIfrmAbsPos = djH.getAbsolutePosition( pWin.bgIframe.iframe, true );
+    var coverIfrm = null;
+    var coverIfrmAbsPos = null;
+    var coverCompStyle = null;
+    if ( pWin.iframesInfo != null && pWin.iframesInfo.iframeCover != null )
+    {
+        coverIfrm = pWin.iframesInfo.iframeCover;
+        coverIfrmAbsPos = djH.getAbsolutePosition( coverIfrm, true );
+        coverCompStyle = djObj.gcs( coverIfrm );
+    }
+    var layoutInfo = pWin._getLayoutInfo();
+    var ind = jsObj.debugindent;
+    var indH = jsObj.debugindentH;
+    djObj.hostenv.println( "wnd-dims [" + pWin.widgetId + "  " + pWin.title + "]" + "  z="
+ dNode.style.zIndex + " hfit=" + pWin.heightToFit );
+    djObj.hostenv.println( ind + "d.abs {x=" + dAbsPos.x + " y=" + dAbsPos.y + "}" + ( isIE
? ( "  hasLayout=" + dNode.currentStyle.hasLayout ) : "" ) );
+    djObj.hostenv.println( ind + "c.abs {x=" + cAbsPos.x + " y=" + cAbsPos.y + "}" + ( isIE
? ( "  hasLayout=" + cNode.currentStyle.hasLayout ) : "" ) );
+    djObj.hostenv.println( ind + "t.abs {x=" + tAbsPos.x + " y=" + tAbsPos.y + "}" + ( isIE
? ( "  hasLayout=" + tbNode.currentStyle.hasLayout ) : "" ) );
+    djObj.hostenv.println( ind + "r.abs {x=" + rAbsPos.x + " y=" + rAbsPos.y + "}" + ( isIE
? ( "  hasLayout=" + rbNode.currentStyle.hasLayout ) : "" ) );
+    if ( bgIfrmAbsPos != null )
+        djObj.hostenv.println( ind + "ibg.abs {x=" + bgIfrmAbsPos.x + " y=" + bgIfrmAbsPos.y
+ "}" + indH + " z=" + pWin.bgIframe.iframe.currentStyle.zIndex + ( isIE ? ( " hasLayout="
+ pWin.bgIframe.iframe.currentStyle.hasLayout ) : "" ) );
+    if ( coverIfrmAbsPos != null )
+        djObj.hostenv.println( ind + "icv.abs {x=" + coverIfrmAbsPos.x + " y=" + coverIfrmAbsPos.y
+ "}" + indH + " z=" + coverCompStyle.zIndex + ( isIE ? ( " hasLayout=" + coverIfrm.currentStyle.hasLayout
) : "" ) );
+    djObj.hostenv.println( ind + "d.mb " + jsObj.debugDims( djObj.getMarginBox( dNode, dCompStyle,
jsObj ) ) + indH + " d.offset {w=" + dNode.offsetWidth + " h=" + dNode.offsetHeight + "}"
);
+    djObj.hostenv.println( ind + "d.cb " + jsObj.debugDims( djObj.getContentBox( dNode, dCompStyle,
jsObj ) ) + indH + " d.client {w=" + dNode.clientWidth + " h=" + dNode.clientHeight + "}"
);
+    djObj.hostenv.println( ind + "d.style {" + jsObj._debugPWinStyle( dNode, dCompStyle,
"width", true ) + jsObj._debugPWinStyle( dNode, dCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
dNode, dCompStyle, "left" ) + jsObj._debugPWinStyle( dNode, dCompStyle, "top" ) + indH + "
pos=" + dCompStyle.position.substring(0,1) + " ofx=" + dCompStyle.overflowX.substring(0,1)
+ " ofy=" + dCompStyle.overflowY.substring(0,1) + "}" );
+    djObj.hostenv.println( ind + "c.mb " + jsObj.debugDims( djObj.getMarginBox( cNode, cCompStyle,
jsObj ) ) + indH + " c.offset {w=" + cNode.offsetWidth + " h=" + cNode.offsetHeight + "}"
);
+    djObj.hostenv.println( ind + "c.cb " + jsObj.debugDims( djObj.getContentBox( cNode, cCompStyle,
jsObj ) ) + indH + " c.client {w=" + cNode.clientWidth + " h=" + cNode.clientHeight + "}"
);
+    djObj.hostenv.println( ind + "c.style {" + jsObj._debugPWinStyle( cNode, cCompStyle,
"width", true ) + jsObj._debugPWinStyle( cNode, cCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
cNode, cCompStyle, "left" ) + jsObj._debugPWinStyle( cNode, cCompStyle, "top" ) + indH + "
ofx=" + cCompStyle.overflowX.substring(0,1) + " ofy=" + cCompStyle.overflowY.substring(0,1)
+ " d=" + cCompStyle.display.substring(0,1) + "}" );
+    djObj.hostenv.println( ind + "t.mb " + jsObj.debugDims( djObj.getMarginBox( tbNode, tCompStyle,
jsObj ) ) + indH + " t.offset {w=" + tbNode.offsetWidth + " h=" + tbNode.offsetHeight + "}"
);
+    djObj.hostenv.println( ind + "t.cb " + jsObj.debugDims( djObj.getContentBox( tbNode,
tCompStyle, jsObj ) ) + indH + " t.client {w=" + tbNode.clientWidth + " h=" + tbNode.clientHeight
+ "}" );
+    djObj.hostenv.println( ind + "t.style {" + jsObj._debugPWinStyle( tbNode, tCompStyle,
"width", true ) + jsObj._debugPWinStyle( tbNode, tCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
tbNode, tCompStyle, "left" ) + jsObj._debugPWinStyle( tbNode, tCompStyle, "top" ) + "}" );
+    djObj.hostenv.println( ind + "r.mb " + jsObj.debugDims( djObj.getMarginBox( rbNode, rCompStyle,
jsObj ) ) + indH + " r.offset {w=" + rbNode.offsetWidth + " h=" + rbNode.offsetHeight + "}"
);
+    djObj.hostenv.println( ind + "r.cb " + jsObj.debugDims( djObj.getContentBox( rbNode,
rCompStyle, jsObj ) ) + indH + " r.client {w=" + rbNode.clientWidth + " h=" + rbNode.clientHeight
+ "}" );
+    djObj.hostenv.println( ind + "r.style {" + jsObj._debugPWinStyle( rbNode, rCompStyle,
"width", true ) + jsObj._debugPWinStyle( rbNode, rCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
rbNode, rCompStyle, "left" ) + jsObj._debugPWinStyle( rbNode, rCompStyle, "top" ) + "}" );
+    if ( bgIfrmAbsPos != null )
+    {
+        var iNode = pWin.bgIframe.iframe;
+        var iCompStyle = djObj.gcs( iNode );
+        djObj.hostenv.println( ind + "ibg.mb " + jsObj.debugDims( djObj.getMarginBox( iNode,
iCompStyle, jsObj ) ) );
+        djObj.hostenv.println( ind + "ibg.cb " + jsObj.debugDims( djObj.getContentBox( iNode,
iCompStyle, jsObj ) ) );
+        djObj.hostenv.println( ind + "ibg.style {" + jsObj._debugPWinStyle( iNode, iCompStyle,
"width", true ) + jsObj._debugPWinStyle( iNode, iCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
iNode, iCompStyle, "left" ) + jsObj._debugPWinStyle( iNode, iCompStyle, "top" ) + indH + "
pos=" + iCompStyle.position.substring(0,1) + " ofx=" + iCompStyle.overflowX.substring(0,1)
+ " ofy=" + iCompStyle.overflowY.substring(0,1) + " d=" + iCompStyle.display.substring(0,1)
+ "}" );
+    }
+    if ( coverIfrm )
+    {
+        djObj.hostenv.println( ind + "icv.mb " + jsObj.debugDims( djObj.getMarginBox( coverIfrm,
coverCompStyle, jsObj ) ) );
+        djObj.hostenv.println( ind + "icv.cb " + jsObj.debugDims( djObj.getContentBox( coverIfrm,
coverCompStyle, jsObj ) ) );
+        djObj.hostenv.println( ind + "icv.style {" + jsObj._debugPWinStyle( coverIfrm, coverCompStyle,
"width", true ) + jsObj._debugPWinStyle( coverIfrm, coverCompStyle, "height" ) + indH + jsObj._debugPWinStyle(
coverIfrm, coverCompStyle, "left" ) + jsObj._debugPWinStyle( coverIfrm, coverCompStyle, "top"
) + indH + " pos=" + coverCompStyle.position.substring(0,1) + " ofx=" + coverCompStyle.overflowX.substring(0,1)
+ " ofy=" + coverCompStyle.overflowY.substring(0,1) + " d=" + coverCompStyle.display.substring(0,1)
+ "}" );
+    }
+    //djObj.hostenv.println( ind + "dNodeCss=" + pWin.dNodeCss.join("") );
+    //djObj.hostenv.println( ind + "cNodeCss=" + pWin.cNodeCss.join("") );
+    // + " ieHasLayout=" + layoutInfo.dNode.ieHasLayout
+    var leN = layoutInfo.dNode;
+    djObj.hostenv.println( ind + "dLE {" + "-w=" + leN.lessW + " -h=" + leN.lessH + " mw="
+ leN.mE.w + " mh=" + leN.mE.h + " bw=" + leN.bE.w + " bh=" + leN.bE.h + " pw=" + leN.pE.w
+ " ph=" + leN.pE.h + "}" );
+    leN = layoutInfo.cNode;
+    djObj.hostenv.println( ind + "cLE {" + "-w=" + leN.lessW + " -h=" + leN.lessH + " mw="
+ leN.mE.w + " mh=" + leN.mE.h + " bw=" + leN.bE.w + " bh=" + leN.bE.h + " pw=" + leN.pE.w
+ " ph=" + leN.pE.h + "}" );
+    leN = layoutInfo.tbNode;
+    djObj.hostenv.println( ind + "tLE {" + "-w=" + leN.lessW + " -h=" + leN.lessH + " mw="
+ leN.mE.w + " mh=" + leN.mE.h + " bw=" + leN.bE.w + " bh=" + leN.bE.h + " pw=" + leN.pE.w
+ " ph=" + leN.pE.h + "}" );
+    leN = layoutInfo.rbNode;
+    djObj.hostenv.println( ind + "rLE {" + "-w=" + leN.lessW + " -h=" + leN.lessH + " mw="
+ leN.mE.w + " mh=" + leN.mE.h + " bw=" + leN.bE.w + " bh=" + leN.bE.h + " pw=" + leN.pE.w
+ " ph=" + leN.pE.h + "}" );
+
+    djObj.hostenv.println( ind + "cNode_mBh_LessBars=" + layoutInfo.cNode_mBh_LessBars );
+    djObj.hostenv.println( ind + "dimsTiled " + jsObj.debugDims( pWin.dimsTiled ) );
+    djObj.hostenv.println( ind + "dimsUntiled " + jsObj.debugDims( pWin.dimsUntiled ) );
+    if ( pWin.dimsTiledTemp != null )
+        djObj.hostenv.println( ind + "dimsTiledTemp " + jsObj.debugDims( pWin.dimsTiledTemp
) );
+    if ( pWin.dimsUntiledTemp != null )
+        djObj.hostenv.println( ind + "dimsUntiledTemp=" + jsObj.debugDims( pWin.dimsUntiledTemp
) );
+    djObj.hostenv.println( ind + "--------------------" );
+    //" document-width=" + dojo.html.getMarginBox( document[ "body" ] ).width + " document-height="
+ dojo.html.getMarginBox( document[ "body" ] ).height
+},
+jetspeed.debugDims = function( box, suppressEnd )
+{
+    return ( "{w=" + ( box.w == undefined ? ( box.width == undefined ? "null" : box.width
) : box.w ) + " h=" + ( box.h == undefined ? ( box.height == undefined ? "null" : box.height
) : box.h ) + ( box.l != undefined ? (" l=" + box.l) : ( box.left == undefined ? "" : (" l="
+ box.left) ) ) + ( box.t != undefined ? (" t=" + box.t) : ( box.top == undefined ? "" : ("
t=" + box.top) ) ) + ( box.right != undefined ? (" r=" + box.right) : "" ) + ( box.bottom
!= undefined ? (" b=" + box.bottom) : "" ) + ( ! suppressEnd ? "}" : "" ) ) ;
+};
+jetspeed._debugPWinStyle = function( node, compStyle, propName, omitLeadingSpace )
+{
+    var sStyle = node.style[ propName ];
+    var cStyle = compStyle[ propName ];
+    if ( sStyle == "auto" ) sStyle = "a";
+    if ( cStyle == "auto" ) cStyle = "a";
+    var showVal = null;
+    if ( sStyle == cStyle )
+        showVal = ('"' + cStyle + '"');
+    else
+        showVal = ('"' + sStyle + '"/' + cStyle);
+    return ( (omitLeadingSpace ? "" : " ") + propName.substring( 0, 1 ) + '=' + showVal);
+};
+
 
 // profile functions
 
@@ -363,3 +513,8 @@
         }
     }        
 }
+
+window.getPWin = function( portletWindowId )
+{
+    return jetspeed.page.getPWin( portletWindowId );
+};

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.js?rev=583999&r1=583998&r2=583999&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.js
(original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.js
Thu Oct 11 17:36:47 2007
@@ -62,6 +62,6 @@
 }
 return _13;
 },notifyFailure:function(_19,_1a,_1b,_1c){
-dojo.raise("PortletAddAjaxApiCallbackCL error ["+_1c.toString()+"] url: "+_1b+" type: "+_19+jetspeed.url.formatBindError(_1a));
+dojo.raise("PortletAddAjaxApiCallbackCL error ["+_1c.toString()+"] url: "+_1b+" type: "+_19+jetspeed.formatError(_1a));
 }};
 

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.src.js
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.src.js?rev=583999&r1=583998&r2=583999&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.src.js
(original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/src/webapp/javascript/jetspeed/selector.src.js
Thu Oct 11 17:36:47 2007
@@ -118,6 +118,6 @@
     },
     notifyFailure: function( /* String */ type, /* Object */ error, /* String */ requestUrl,
domainModelObject )
     {
-        dojo.raise( "PortletAddAjaxApiCallbackCL error [" + domainModelObject.toString()
+ "] url: " + requestUrl + " type: " + type + jetspeed.url.formatBindError( error ) );
+        dojo.raise( "PortletAddAjaxApiCallbackCL error [" + domainModelObject.toString()
+ "] url: " + requestUrl + " type: " + type + jetspeed.formatError( error ) );
     }
 };



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