Bug in SWTEventDispatcher? [message #165413] |
Tue, 25 January 2005 03:51  |
Eclipse User |
|
|
|
Hi,
I am trying to get to the cause of a bug in my plugin. My investigations
have led me to the class SWTEventDispatcher. It seems that the mouse
capture and release (along with mouseTarget setting) happen in
dispatchMousePressed() and dispatchMouseReleased(). Further, the
mouseTarget is set to null in dispatchMouseExited() as well, shouldn't
the capture be released in this case (on mouse exit)?
I am trying to show the user a menu after the user clicks on a button.
Since I create the menu on mousePress, the mouseRelease does not seem to
be called (though moseExit is called). The result is that the dispatcher
thinks that the mouse is captured and does not send mouse events to my
mouse listeners on the figures.
Any help in this is appreciated.
Thanks!
Regards,
Vineet
|
|
|
|
Re: Bug in SWTEventDispatcher? [message #165579 is a reply to message #165475] |
Tue, 25 January 2005 18:54   |
Eclipse User |
|
|
|
I spent some more time looking at this. The palette's pin button doesn't
(seem to) do anything on mose press/drag, i.e. on mouse capture, it
only uses toggle. However, it seems that the PaletteStack is able to put
up a popup menu on mouse down by using the Tool.nativeDragStarted(..).
BTW, I forgot to mention earlier, I am using WinXP, and get this with
both GEF 3.0.1 and the latest CVS.
Regards,
Vineet
PS: Would you recommend me to file a bug and submit a patch in bugzilla?
Randy Hudson wrote:
> It sounds like a bug. Besides when popping up menus, dragging outside the
> control will cause an exit event on GTK, which means mouse up won't happen.
> Why haven't we seen this bug already? The palette's "pin open" button is a
> clickable which asks for mouse capture.
|
|
|
Re: Bug in SWTEventDispatcher? [message #165958 is a reply to message #165579] |
Thu, 27 January 2005 11:16  |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
The pin button (Clickable actually) consumes the mousedown event, which
gives it mouse capture. On GTK, it should be possible to drag the mouse
outside the palette while holding down the mouse button, in which case we
would get a mouseExit event, but mouse capture would not get reset, so it
gets stuck on the pin button. Open a bug
"Vineet Sinha" <vineet@csail.mit.edu> wrote in message
news:ct6m6m$m01$1@www.eclipse.org...
>I spent some more time looking at this. The palette's pin button doesn't
>(seem to) do anything on mose press/drag, i.e. on mouse capture, it only
>uses toggle. However, it seems that the PaletteStack is able to put up a
>popup menu on mouse down by using the Tool.nativeDragStarted(..).
>
> BTW, I forgot to mention earlier, I am using WinXP, and get this with both
> GEF 3.0.1 and the latest CVS.
>
> Regards,
> Vineet
>
>
> PS: Would you recommend me to file a bug and submit a patch in bugzilla?
>
>
>
> Randy Hudson wrote:
>> It sounds like a bug. Besides when popping up menus, dragging outside
>> the control will cause an exit event on GTK, which means mouse up won't
>> happen. Why haven't we seen this bug already? The palette's "pin open"
>> button is a clickable which asks for mouse capture.
|
|
|
Powered by
FUDForum. Page generated in 0.03952 seconds