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

MouseDrag events are not delivered to the component when they are non-focusable

XMLWordPrintable

    • Fix Understood
    • x86
    • windows_xp

      Setting focusability to false for any component prevents it from receiving MouseDragged events when the mouse goes out of the component. According to the specification, MouseDragged events must be delivered to the component regardless of where the mouse pointer is, as long as the mouse button is down. This does not say anything about the component focusability. This works as expected when the component is focusable.

      This is reproducible only on win32 platforms right from JDK1.4. This is not reproducible on Solaris / Linux.

      I have attached a sample test. You would see 4 checkboxes and a button. The button and the first checkbox are non-focusable. Click one of them and drag the mouse out of the frame. If the mouse dragged events stops triggering after mouse comes out of the component, the bug is reproduced.

            dav Andrei Dmitriev (Inactive)
            pmohansunw Praveen Mohan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Imported:
              Indexed: