/[classpath]/classpath/javax/swing/plaf/basic/BasicIconFactory.java
ViewVC logotype

Diff of /classpath/javax/swing/plaf/basic/BasicIconFactory.java

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

revision 1.10 by rabbit78, Thu Jul 21 12:07:06 2005 UTC revision 1.11 by langel, Wed Aug 3 18:09:44 2005 UTC
# Line 157  public class BasicIconFactory implements Line 157  public class BasicIconFactory implements
157        // The icon is empty and needs no painting.        // The icon is empty and needs no painting.
158      }      }
159    }    }
   
160    /** The cached CheckBoxIcon instance. */    /** The cached CheckBoxIcon instance. */
161    private static CheckBoxIcon checkBoxIcon;    private static CheckBoxIcon checkBoxIcon;
162      
163    /** The cached CheckBoxIcon instance. */    /** The cached RadioButtonIcon instance. */
164    private static RadioButtonIcon radioButtonIcon;    private static RadioButtonIcon radioButtonIcon;
165    
166    public static Icon getMenuItemCheckIcon()    public static Icon getMenuItemCheckIcon()
167    {    {
168      return new DummyIcon();      return new Icon()
169        {
170          public int getIconHeight()
171          {
172            return 13;
173          }
174    
175          public int getIconWidth()
176          {
177            return 13;
178          }
179    
180          public void paintIcon(Component c, Graphics g, int x, int y)
181          {
182            Color saved = g.getColor();
183            g.setColor(Color.BLACK);
184            g.drawLine(3 + x, 5 + y, 3 + x, 9 + y);
185            g.drawLine(4 + x, 5 + y, 4 + x, 9 + y);
186            g.drawLine(5 + x, 7 + y, 9 + x, 3 + y);
187            g.drawLine(5 + x, 8 + y, 9 + x, 4 + y);
188            g.setColor(saved);
189          }
190        };
191    }    }
192    public static Icon getMenuItemArrowIcon()    public static Icon getMenuItemArrowIcon()
193    {    {
# Line 236  public class BasicIconFactory implements Line 257  public class BasicIconFactory implements
257    {    {
258      return getCheckBoxIcon();      return getCheckBoxIcon();
259    }    }
260      
261    public static Icon getRadioButtonMenuItemIcon()    public static Icon getRadioButtonMenuItemIcon()
262    {    {
263      return getRadioButtonIcon();      return getRadioButtonIcon();
264    }    }
265      
266    public static Icon createEmptyFrameIcon()    public static Icon createEmptyFrameIcon()
267    {    {
268      return new DummyIcon();      return new DummyIcon();

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.11

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