portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From woon...@apache.org
Subject svn commit: r772640 - /portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java
Date Thu, 07 May 2009 12:56:00 GMT
Author: woonsan
Date: Thu May  7 12:56:00 2009
New Revision: 772640

URL: http://svn.apache.org/viewvc?rev=772640&view=rev
Log:
JS2-990: Fixing a problem not to copy portlet default preferences. Thanks to Vivek for pointing
out this!

Modified:
    portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java?rev=772640&r1=772639&r2=772640&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java
(original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-registry/src/main/java/org/apache/jetspeed/components/portletregistry/PersistenceBrokerPortletRegistry.java
Thu May  7 12:56:00 2009
@@ -462,7 +462,9 @@
         }
         for (Preference pref : source.getPortletPreferences().getPortletPreferences())
         {
-            Preference copyPref = copy.getPortletPreferences().addPreference(pref.getName());
+            Preference copyPref = copy.addDescriptorPreference(pref.getName());
+            copyPref.setReadOnly(pref.isReadOnly());
+            
             for (String value : pref.getValues())
             {
                 copyPref.addValue(value);
@@ -474,7 +476,7 @@
         }
         catch (Throwable e)
         {
-            source.getApplication().getPortlets().remove(copy);            
+            source.getApplication().getPortlets().remove(copy);
             throw new FailedToStorePortletDefinitionException(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