-
Bug
-
Resolution: Fixed
-
P4
-
1.1, 1.1.1, 1.1.4, 1.1.5, 1.2.0
-
b01
-
generic, x86
-
generic, windows_95, windows_nt
-
Not verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2014260 | 1.2.0 | Robi Khan | P4 | Resolved | Fixed | 1.2beta4 |
Name: mc57594 Date: 02/27/97
1) In the example given, click in the red area and move the mouse
out of the red area quickly. Note that DRAG events are not delivered.
In addition the mouse released event is not delivered when the mouse
is released. When the red component receives two mouse downs in a row
without a mouse up it will print ERROR: in the output window.
2) Source Code: (Stand Alone Example)
import java.awt.*;
import java.awt.event.*;
class DragBug
extends Panel
{
public DragBug()
{
addMouseMotionListener(new IMouseMotionAdapter());
addMouseListener(new IMouseAdapter());
setBackground(Color.red);
}
public Dimension preferredSize()
{
return new Dimension(50,50);
}
class IMouseMotionAdapter extends MouseMotionAdapter
{
public IMouseMotionAdapter(){}
public void mouseDragged(MouseEvent e)
{
System.out.println("DragBug: DragEvent");
}
}
class IMouseAdapter extends MouseAdapter
{
public IMouseAdapter(){}
public void mousePressed(MouseEvent e)
{
System.out.println("DragBug: MousePressed");
if (ivHasMouse)
{
System.out.println("ERROR: Mouse pressed in a row without release!!");
}
ivHasMouse = true;
}
public void mouseReleased(MouseEvent e)
{
System.out.println("DragBug: MouseReleased");
ivHasMouse = false;
}
}
public boolean ivHasMouse = false;
}
public class DragBugDemo
{
public static void main(String args[])
{
Frame f = new Frame("DragBug");
f.setLayout(new FlowLayout());
f.add(new DragBug());
f.setBounds(new Rectangle(20,20,300,300));
f.show();
}
}
3) No error messages. Behvaior BUG
4) Trace from program. Notice the two mouse pressed events.
and no drag events.
DragBug: DragEvent
DragBug: MouseReleased
DragBug: MousePressed
DragBug: MousePressed
ERROR: Mouse pressed in a row without release!!
DragBug: MouseReleased
DragBug: MousePressed
DragBug: MouseReleased
5)Plain Win 95
company - Shafir Inc. , email - ###@###.###
======================================================================
- backported by
-
JDK-2014260 MAJOR! Drag events and mouse released events not delivered if mouse is moved qui
- Resolved
- duplicates
-
JDK-4095216 MOUSE_RELEASED events not being generated
- Closed
-
JDK-4027756 Mouse events delivered to wrong components.
- Closed
-
JDK-4034656 Win32:MouseDrag issues an event incorrectly
- Closed
-
JDK-4047366 Win32: mouseUp events aren't reliably reported after a fast drag
- Closed
-
JDK-4080787 Mouse Drag Events not sent if you move the mouse off the Component quickly
- Closed
-
JDK-4121222 Windows are stealing mouse-dragged events on Wintel AWT
- Closed
-
JDK-4126077 Erroneous Mouse Drag event
- Closed
-
JDK-4129112 JToolBar re-floating doesn't work
- Closed
-
JDK-4133252 Stylepad Example toolbar cannot be torn off twice
- Closed
-
JDK-4135334 JToolBar remains stuck at a certain position after detaching it
- Closed
-
JDK-4034797 Mouse event sequence not correct
- Closed
- relates to
-
JDK-4074498 JDK REGRESSION: Setting the cursor to MOVE_CURSOR on Win32 doesn't work.
- Closed
-
JDK-4083025 mouseDragged events don't always come from the component where drag originated
- Closed