portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject cvs commit: jakarta-jetspeed-2/components/web-content/src/java/org/apache/jetspeed/portlet IFrameGenericPortlet.java
Date Mon, 15 Nov 2004 05:58:10 GMT
taylor      2004/11/14 21:58:10

  Modified:    components/web-content/src/java/org/apache/jetspeed/portlet
                        IFrameGenericPortlet.java
  Log:
  moved up prefs support in the class hiearchy
  
  Revision  Changes    Path
  1.3       +4 -16     jakarta-jetspeed-2/components/web-content/src/java/org/apache/jetspeed/portlet/IFrameGenericPortlet.java
  
  Index: IFrameGenericPortlet.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/components/web-content/src/java/org/apache/jetspeed/portlet/IFrameGenericPortlet.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- IFrameGenericPortlet.java	12 Nov 2004 19:34:51 -0000	1.2
  +++ IFrameGenericPortlet.java	15 Nov 2004 05:58:10 -0000	1.3
  @@ -17,24 +17,18 @@
   
   import java.io.IOException;
   import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.Map;
   
   import javax.portlet.ActionRequest;
   import javax.portlet.ActionResponse;
   import javax.portlet.PortletConfig;
   import javax.portlet.PortletException;
  -import javax.portlet.PortletMode;
   import javax.portlet.PortletPreferences;
   import javax.portlet.RenderRequest;
   import javax.portlet.RenderResponse;
   import javax.portlet.WindowState;
   
   import org.apache.portals.bridges.velocity.GenericVelocityPortlet;
  -import org.apache.velocity.context.Context;
  -
  -import org.apache.portals.bridges.util.PreferencesHelper;
  -
   
   /**
    * IFrameGenericPortlet
  @@ -116,11 +110,8 @@
   
       public void doEdit(RenderRequest request, RenderResponse response) throws PortletException,
IOException
       {
  -        Context context = getContext(request);
  -        PortletPreferences prefs = request.getPreferences();
  -        Iterator it = prefs.getMap().entrySet().iterator();
  -        context.put("prefs", it);
  -        super.doEdit(request, response);
  +        response.setContentType("text/html");        
  +        doPreferencesEdit(request, response);        
       }
       
       /**
  @@ -170,10 +161,7 @@
       public void processAction(ActionRequest request, ActionResponse actionResponse)
       throws PortletException, IOException
       {
  -        PortletPreferences prefs = request.getPreferences();
  -        PreferencesHelper.requestParamsToPreferences(request);
  -        prefs.store();
  -        actionResponse.setPortletMode(PortletMode.VIEW);
  +        processPreferencesAction(request, actionResponse);
       }
       
   }
  
  
  

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


Mime
View raw message