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

JSpinner:Unable to scroll up/down the HOUR field using SpinnerDateModel

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2 P2
    • 1.4.0
    • 1.4.0
    • client-libs
    • beta2
    • sparc
    • solaris_7
    • Verified

      Run the code snippet given below. I could scroll up/down all fields except the HOUR where it gives a beep sound if I tried scrolling it.

      % java -version
      java version "1.4.0-beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta-b58)
      Java HotSpot(TM) Client VM (build 1.4.0-beta-b58, mixed mode)

      Code used:
      import java.awt.*;
      import java.util.*;
      import javax.swing.*;

      public class spintest extends JFrame {
        JSpinner spin;
        Date todayDate;
        SpinnerDateModel model = new SpinnerDateModel();
        
        public spintest() {
          setSize(150, 70);
          spin = new JSpinner(model);
          todayDate = (Date)model.getValue();
          getContentPane().add(spin);
        }
        
        public static void main(String args[]) {
          spintest s = new spintest();
          s.setVisible(true);
        }
      }

            svioletsunw Scott Violet (Inactive)
            sramansunw Sridhar Raman (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: