/[classpath]/classpath/javax/swing/JCheckBox.java
ViewVC logotype

Diff of /classpath/javax/swing/JCheckBox.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.10.2.2 by gnu_andrew, Tue Aug 2 20:12:37 2005 UTC revision 1.10.2.3 by gnu_andrew, Tue Sep 20 18:46:31 2005 UTC
# Line 38  exception statement from your version. * Line 38  exception statement from your version. *
38    
39  package javax.swing;  package javax.swing;
40    
41    import javax.accessibility.Accessible;
42  import javax.accessibility.AccessibleContext;  import javax.accessibility.AccessibleContext;
43    import javax.accessibility.AccessibleRole;
44    
45  /**  /**
46   * A small box that displays a check or not, depending on it's   * A small box that displays a check or not, depending on it's
# Line 54  import javax.accessibility.AccessibleCon Line 56  import javax.accessibility.AccessibleCon
56   *   *
57   * @author Ronald Veldema (rveldema@cs.vu.nl)   * @author Ronald Veldema (rveldema@cs.vu.nl)
58   */   */
59  public class JCheckBox extends JToggleButton  public class JCheckBox extends JToggleButton implements Accessible
60  {  {
61    
62      /**
63       * Provides accessibility support for <code>JCheckBox</code>.
64       */
65      protected class AccessibleJCheckBox extends AccessibleJToggleButton
66      {
67        /**
68         * Creates a new instance of <code>AccessibleJCheckBox</code>.
69         */
70        public AccessibleJCheckBox()
71        {
72          // Nothing to do here.
73        }
74    
75        /**
76         * Returns the accessble role of <code>JCheckBox</code>,
77         * {@link AccessibleRole#CHECK_BOX}.
78         */
79        public AccessibleRole getAccessibleRole()
80        {
81          return AccessibleRole.CHECK_BOX;
82        }
83      }
84    
85    private static final long serialVersionUID = -5246739313864538930L;    private static final long serialVersionUID = -5246739313864538930L;
86    
87    public static final String BORDER_PAINTED_FLAT_CHANGED_PROPERTY =    public static final String BORDER_PAINTED_FLAT_CHANGED_PROPERTY =
# Line 118  public class JCheckBox extends JToggleBu Line 144  public class JCheckBox extends JToggleBu
144    }    }
145    
146    /**    /**
    * Gets the AccessibleContext associated with this JCheckBox.  
    */  
   public AccessibleContext getAccessibleContext()  
   {  
     return null;  
   }  
     
   /**  
147     * Returns a string that specifies the name of the Look and Feel class     * Returns a string that specifies the name of the Look and Feel class
148     * that renders this component.     * that renders this component.
149     */     */
# Line 149  public class JCheckBox extends JToggleBu Line 167  public class JCheckBox extends JToggleBu
167      firePropertyChange("borderPaintedFlat", borderPaintedFlat, newValue);      firePropertyChange("borderPaintedFlat", borderPaintedFlat, newValue);
168      borderPaintedFlat = newValue;      borderPaintedFlat = newValue;
169    }    }
170    
171      /**
172       * Returns the accessible context for this <code>JCheckBox</code>.
173       *
174       * @return the accessible context for this <code>JCheckBox</code>
175       */
176      public AccessibleContext getAccessibleContext()
177      {
178        if (accessibleContext == null)
179          accessibleContext = new AccessibleJCheckBox();
180        return accessibleContext;
181      }
182  }  }

Legend:
Removed from v.1.10.2.2  
changed lines
  Added in v.1.10.2.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26