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

XToolkit: calling toFront() on Frame generates unexpected COMPONENT_RESIZED even

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P1
    • Resolution: Fixed
    • Affects Version/s: 5.0
    • Fix Version/s: 5.0
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b30
    • CPU:
      x86
    • OS:
      linux

      Description



      Name: atR10251 Date: 10/23/2003


      Unexpected COMPONENT_RESIZED event is generated when toFront() is
      called.
      This occures on XAWT only.
      Run the test below to reproduce the problem.

      =============== TEST CASE ==================
      import java.awt.*;
      import java.awt.event.*;

      public class ToFrontTest {

          public static void main(String[] args)
            throws Exception
          {
              final Frame f1 = new Frame("F-0"), f2 = new Frame("F-1");
              f1.setSize(200, 100);
              f2.setSize(200, 100);
              f2.setLocation(f1.getX() + 210, f1.getY());
              f1.setVisible(true);
              f2.setVisible(true);

              Thread.sleep(1000);

              Toolkit.getDefaultToolkit().addAWTEventListener(new
      AWTEventListener() {
                      public void eventDispatched(AWTEvent e) {
                          if (e.getSource() == f1) {
                              System.err.println(e);
                          }
                      }
                  }, ComponentEvent.COMPONENT_EVENT_MASK);

              f1.toFront();
          }
      }
      ================= END ====================
      ======================================================================

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                dmikhalksunw Denis Mikhalkin (Inactive)
                Reporter:
                ant Anton Tarasov
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: