This patch implements the HTML reader HiddenAction. Little should be done here, the parser already cares about the most.

2006-06-10  Audrius Meskauskas  <[EMAIL PROTECTED]>

   * javax/swing/text/html/HTMLDocument.java
   (HTMLReader.HiddenAction): Implemented.
Index: HTMLDocument.java
===================================================================
RCS file: /sources/classpath/classpath/javax/swing/text/html/HTMLDocument.java,v
retrieving revision 1.32
diff -u -r1.32 HTMLDocument.java
--- HTMLDocument.java	9 Jun 2006 12:51:24 -0000	1.32
+++ HTMLDocument.java	10 Jun 2006 09:04:15 -0000
@@ -648,17 +648,25 @@
       } 
     }
     
-    public class HiddenAction extends TagAction
+    /**
+     * This action indicates that the content between starting and closing HTML
+     * elements (like script - /script) should not be visible. The content is
+     * still inserted and can be accessed when iterating the HTML document. The
+     * parser will only fire
+     * [EMAIL PROTECTED] javax.swing.text.html.HTMLEditorKit.ParserCallback#handleText} for
+     * the hidden tags, regardless from that html tags the hidden section may
+     * contain.
+     */
+    public class HiddenAction
+        extends TagAction
     {
       /**
        * This method is called when a start tag is seen for one of the types
        * of tags associated with this Action.
        */
       public void start(HTML.Tag t, MutableAttributeSet a)
-        throws NotImplementedException
       {
-        // FIXME: Implement.
-        print ("HiddenAction.start not implemented");
+        blockOpen(t, a);
       }
       
       /**
@@ -666,10 +674,8 @@
        * with this Action.
        */
       public void end(HTML.Tag t)
-        throws NotImplementedException
       {
-        // FIXME: Implement.
-        print ("HiddenAction.end not implemented");
+        blockClose(t);
       } 
     }
     

Reply via email to