This content has been marked as final.
Show 2 replies
-
1. Re: How to set empty renders for portlets
dvanwest Apr 17, 2009 1:22 PM (in response to peris)We typically indicate the empty renderer in the page description file portal-object.xml. Not sure this approach will meet your needs.
<window> <window-name>Intro</window-name> <instance-ref>introInstance</instance-ref> <region>top</region> <height>2</height> <properties> <property> <name>theme.renderSetId</name> <value>emptyRenderer</value> </property> </properties> </window>
As for preventing drag & drop for windows within a specific region... we modified the dyna.js file to remove the drag & drop hooks for any window regions within an enclosing div which has a special class name we use to indicate the region shouldn't allow drag or drop activity. We add the special class name to a region in the layout JSP.
Maybe others have a better solution? -
2. Re: How to set empty renders for portlets
vivek_saini07 Apr 18, 2009 6:04 AM (in response to peris)
2) Is it possible to prevent the drag and drop functionalities in left region only ?.
I achived this by modifying renderHeader of DynaRegionRenderer.java
Region for which DnD to be disabled, region name will contain "NonDnD".if (options.isDnDEnabled()) { List win =(List)rrc.getWindows(); boolean isDnD=false; Iterator it=win.iterator(); while(it.hasNext()) { WindowContext po=(WindowContext)it.next(); if(po.getRegionName().indexOf("NonDnD")==-1) { markup.print("<div class=\"dnd-region\" id=\""); markup.print(rrc.getId()); markup.print("\">"); } Map mapObj=po.getProperties(); } // markup.print("<div class=\"dnd-region\" id=\""); // markup.print(rrc.getId()); // markup.print("\">"); } } else { delegate.renderHeader(rendererContext, rrc); }