Bug 482022 - [win32] MouseEnter not fired on fast traversals
Summary: [win32] MouseEnter not fired on fast traversals
Status: REOPENED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.11   Edit
Hardware: PC Windows 10
: P3 major with 2 votes (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-12 10:40 EST by DaveLaw CLA
Modified: 2023-01-09 05:01 EST (History)
4 users (show)

See Also:


Attachments
Example Program highlighting the problem. (2.39 KB, text/plain)
2015-11-12 10:43 EST, DaveLaw CLA
no flags Details
An updated snippet which prints in console only when there's an error. (2.52 KB, application/octet-stream)
2015-11-13 07:34 EST, Niraj Modi CLA
no flags Details
Refined Snippet (4.42 KB, text/plain)
2015-11-14 08:54 EST, DaveLaw CLA
no flags Details
Revised Snippet to run under SWT v4.11 (6.33 KB, text/plain)
2019-05-22 05:05 EDT, DaveLaw CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description DaveLaw CLA 2015-11-12 10:40:58 EST
MouseEnter events are sometimes not being fired (or are being lost)
The attached program highlights this.

Traversing as fast as possible with the mouse from left of the window to right of the window fires MouseEnter & MouseExit for all 3 Canvases (see Console).

The 3 Canvases do not overlap, in fact there is a gap between them.

Traversing very fast between, say, the Red & Green Canvases, (only sometimes) the MouseEnter event is not fired. Optically noticable due to the Arrow Cursor.
(normally after entering, the Hand Cursor is shown)

This can also be verified in the Console log.

The MouseExit event seems always to fire.
Comment 1 DaveLaw CLA 2015-11-12 10:43:59 EST
Created attachment 257901 [details]
Example Program highlighting the problem.
Comment 2 Niraj Modi CLA 2015-11-13 07:34:35 EST
Created attachment 257920 [details]
An updated snippet which prints in console only when there's an error.

Not able to reproduce this issue on Windows7, Is it Windows8 specific ?
Comment 3 DaveLaw CLA 2015-11-13 15:06:48 EST
ok, I've tried it under Windows Vista & Windows 7 & cannot reproduce it.

On the original Windows 8.1 PC I have tried 2 vanilla eclipse installations:
- Mars v4.5.0: Eclipse IDE for Java EE Developers 64 bit
- Mars v4.5.1: Eclipse IDE for Java EE Developers 64 bit

On both I installed WindowBuilder Pro.
WindowBuilder Pro was then used to create a new SWT/JFace Java Project.

The problem was observed on BOTH vanilla IDE environments.

Java Version for Eclipse & Project is 1.8.0_51 64 bit.
I thought maybe its a problem with the cheap amazon mouse driver & disconnected it.
But the problem was reproducible via the touchpad too.

Where to from here?
Comment 4 DaveLaw CLA 2015-11-14 08:53:13 EST
Niraj,

it was a good idea to just filter the errors to the console, but it didn't quite work as intended, so I've refined it further.
See attachment  "Refined Snippet".
Comment 5 DaveLaw CLA 2015-11-14 08:54:59 EST
Created attachment 257942 [details]
Refined Snippet
Comment 6 DaveLaw CLA 2015-11-17 16:24:02 EST
ok, we have now been able to test this on several Windows 10 PC's.
I can confirm, the problem also occurs on Windows 10.
Comment 7 Niraj Modi CLA 2015-11-18 04:11:37 EST
(In reply to DaveLaw from comment #0)
So, just traversing the mouse very fast alone, doesn't shows up the issue for me.

First I need to click on any of the colored canvas and then traversing the mouse very fast(for some time) will lead to console error:
e.g. When I click on Red Canvas then I traverse very fast I get below error with Refined Snippet:
Error:
Prev @ 2015.11.18 14:28:25.130 Mouse Exit..: Canvas 0 (Red)	fffffff9d919916 MouseEvent{Bug482022$MouseCanvas {} time=22129046 data=null button=0 stateMask=0x0 x=130 y=34 count=0}
This @ 2015.11.18 14:28:25.162 Mouse Exit..: Canvas 1 (Green)	fffffffcde84f29 MouseEvent{Bug482022$MouseCanvas {} time=22129078 data=null button=0 stateMask=0x0 x=158 y=34 count=0}

With my tests, I could see a pattern here, which ever Canvas you clicked, you will notice error only while existing that particular canvas, so when I clicked on Red Canvas and Error that follows is seen with Mouse Exit for (RED) and Mouse Exit for (Green) combination only.

Bug reproducible on Win81 & Win10.
Comment 8 DaveLaw CLA 2015-11-18 05:33:25 EST
Hi Niraj,
nice to hear its reproducible there too.
Here its sufficient to just position the mouse, click is not necessary.
Just a few distinct jerky movements are enough, nothing wild.
Comment 9 DaveLaw CLA 2016-09-23 04:23:47 EDT
Now nearly a year has passed.
Is there any progress with this - rather serious - bug?
Comment 10 DaveLaw CLA 2016-11-03 06:06:46 EDT
Still no change: increasing severity to critical.
Comment 11 DaveLaw CLA 2017-05-28 13:07:01 EDT
Error still persists with eclipse Oxygen 4.7.0 RC2 and JDK 9 ea 171.
Comment 12 Niraj Modi CLA 2017-05-31 04:27:09 EDT
A fix patch is welcome, here.

Am not sure if, Widget#wmMouseMove() method does force dispatch outstanding WM_MOUSELEAVE messages, will have to check if that piece of code is still needed for Win version 8.1 and on-wards, targeting for 4.8
Comment 13 Niraj Modi CLA 2018-05-14 05:37:01 EDT
Moving to 4.9, please re-target as required.
Comment 14 DaveLaw CLA 2019-05-22 05:03:06 EDT
We're heading for 4 years since this was reported, so I though I'd check if it's still an issue.

I've uploaded a new version of the Test Programme which runs under the current SWT version, as OS.getTickCount() was removed in SWT v4.8.

Also, I've tried it out under Ubuntu 18.04 (Linux Mint 19.1), but the problem does not seem to occur there.

But YES, under Windows 10 the problem still persists with SWT v4.11.
Comment 15 DaveLaw CLA 2019-05-22 05:05:55 EDT
Created attachment 278689 [details]
Revised Snippet to run under SWT v4.11
Comment 16 Eclipse Genie CLA 2021-05-12 00:17:17 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 17 DaveLaw CLA 2021-05-12 07:24:51 EDT
The problem still persists with v4.19 (2021-03)
Comment 18 DaveLaw CLA 2023-01-09 03:49:18 EST
Another 18 Months have gone by & still nothing done about this serious issue
Comment 19 Andrey Loskutov CLA 2023-01-09 04:20:22 EST
(In reply to DaveLaw from comment #18)
> Another 18 Months have gone by & still nothing done about this serious issue

Well, if it is important issue for you, please consider to provide a test and a pull request.

Note: bug tracker is moved to https://github.com/eclipse-platform/eclipse.platform.swt/issues
Comment 20 DaveLaw CLA 2023-01-09 04:27:12 EST
(In reply to Andrey Loskutov from comment #19)
> (In reply to DaveLaw from comment #18)
> > Another 18 Months have gone by & still nothing done about this serious issue
> 
> Well, if it is important issue for you, please consider to provide a test
> and a pull request.
> 
> Note: bug tracker is moved to
> https://github.com/eclipse-platform/eclipse.platform.swt/issues

I would love to, but I'm not a C-Programmer.
Comment 21 DaveLaw CLA 2023-01-09 05:01:42 EST
Issue posted to github:
https://github.com/eclipse-platform/eclipse.platform.swt/issues/523