Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4097719

JRadioButtonMenuItem(Icon) and RadioButtonMenuItem(String,Icon) don't set Icon

XMLWordPrintable

    • sparc
    • solaris_2.5.1



      Name: aaC67449 Date: 12/08/97



      Constructors JRadioButtonMenuItem(Icon) and RadioButtonMenuItem(String,Icon) don't set Icon.

      ------------Example--------
      import java.awt.swing.*;
      import java.awt.swing.basic.*;
      public class Test {

      public static void main( String argv[] ) {
          Icon i=BasicIconFactory.createFrameIconifyIcon();
          JRadioButtonMenuItem f=new JRadioButtonMenuItem (i);
          if(!f.getIcon().equals(i))
              System.out.println("FAILED");
          else
              System.out.println("PASSED");

           f=new JRadioButtonMenuItem ("",i);
          if(!f.getIcon().equals(i))
              System.out.println("FAILED");
          else
              System.out.println("PASSED");


       }

      }
      ------------Output----------
      FAILED
      FAILED
      ------



      ======================================================================

            Unassigned Unassigned
            aalievsunw Artem Aliev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: