tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From patri...@apache.org
Subject cvs commit: jakarta-tomcat-4.0/webapps/admin/WEB-INF/classes/org/apache/webapp/admin TreeControlTestAction.java
Date Wed, 28 Nov 2001 03:33:49 GMT
patrickl    01/11/27 19:33:49

  Modified:    webapps/admin/WEB-INF/classes/org/apache/webapp/admin
                        TreeControlTestAction.java
  Log:
  Removed extraneous code
  Submitted by:	Jazmin Jonson
  
  Revision  Changes    Path
  1.3       +15 -29    jakarta-tomcat-4.0/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/TreeControlTestAction.java
  
  Index: TreeControlTestAction.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/TreeControlTestAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TreeControlTestAction.java	2001/11/27 02:46:28	1.2
  +++ TreeControlTestAction.java	2001/11/28 03:33:49	1.3
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/TreeControlTestAction.java,v
1.2 2001/11/27 02:46:28 patrickl Exp $
  - * $Revision: 1.2 $
  - * $Date: 2001/11/27 02:46:28 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/TreeControlTestAction.java,v
1.3 2001/11/28 03:33:49 patrickl Exp $
  + * $Revision: 1.3 $
  + * $Date: 2001/11/28 03:33:49 $
    *
    * ====================================================================
    *
  @@ -84,7 +84,7 @@
    * page.
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.2 $ $Date: 2001/11/27 02:46:28 $
  + * @version $Revision: 1.3 $ $Date: 2001/11/28 03:33:49 $
    */
   
   public class TreeControlTestAction extends Action {
  @@ -113,47 +113,33 @@
                                    HttpServletRequest request,
                                    HttpServletResponse response)
           throws IOException, ServletException {
  -            
   
  -	getServlet().log("Entered TreeControlTestAction:perform()");
  +        getServlet().log("Entered TreeControlTestAction:perform()");
  +
           String name = null;
  -	String encodedName = null;
           HttpSession session = request.getSession();
           TreeControl control =
               (TreeControl) session.getAttribute("treeControlTest");
   
           // Handle a tree expand/contract event
  -        encodedName = request.getParameter("tree");
  -
  -        if (encodedName != null) {
  -
  -        // HACK to take into account special characters like = and &
  -        // in the node name, could remove this code if encode URL
  -        // and request.getParameter() could deal with = and &
  -        // character in parameter values. 
  -            name = URLDecoder.decode(encodedName);
  -
  +        name = request.getParameter("tree");
   
  +        if (name != null) {
               getServlet().log("Tree expand/contract on " + name);
  +
               TreeControlNode node = control.findNode(name);
  +
               if (node != null){
  -		getServlet().log("Found Node: " + name);
  +                getServlet().log("Found Node: " + name);
                   node.setExpanded(!node.isExpanded());
  -	    }
  +            }
           }else{
               getServlet().log("tree param is null");
  -	}
  +        }
   
           // Handle a select item event
  -        encodedName = request.getParameter("select");
  -        if (encodedName != null) {
  -
  -           // HACK to take into account special characters like = and &
  -           // in the node name, could remove this code if encode URL
  -           // and request.getParameter() could deal with = and &
  -           // character in parameter values. 
  -            name = URLDecoder.decode(encodedName);
  -
  +        name = request.getParameter("select");
  +        if (name != null) {
               getServlet().log("Select event on " + name);
               control.selectNode(name);
           }
  
  
  

--
To unsubscribe, e-mail:   <mailto:tomcat-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-dev-help@jakarta.apache.org>


Mime
View raw message