Closed Bug 1300003 Opened 8 years ago Closed 8 years ago

NativeKey should remove all following WM_CHAR messages at handling WM_KEYDOWN first

Categories

(Core :: Widget: Win32, defect, P2)

All
Windows
defect

Tracking

()

RESOLVED FIXED
mozilla52
Tracking Status
firefox51 --- fix-optional
firefox52 --- fixed

People

(Reporter: masayuki, Assigned: masayuki)

References

(Depends on 1 open bug)

Details

(Whiteboard: tpi:+)

Attachments

(6 files)

58 bytes, text/x-review-board-request
m_kato
: review+
Details
58 bytes, text/x-review-board-request
m_kato
: review+
Details
58 bytes, text/x-review-board-request
m_kato
: review+
Details
58 bytes, text/x-review-board-request
m_kato
: review+
Details
58 bytes, text/x-review-board-request
m_kato
: review+
Details
58 bytes, text/x-review-board-request
m_kato
: review+
Details
NativeKey currently removes WM_CHAR messages from the queue after dispatching eKeyDown event. However, that means that following WM_CHAR messages may be gone during dispatching eKeyDown event, e.g., if it causes entering into modal dialog.

Additionally, we cannot log all WM_CHAR messages when we have two or more characters at a keypress.

For solving these issues, NativeKey should remove all following WM_CHAR messages at starting to handle WM_KEYDOWN and cache them until eKeyPress events are dispatched.
Priority: -- → P2
Whiteboard: tpi:+
Comment on attachment 8791563 [details]
Bug 1300003 part.1 NativeKey should remove following char messages before dispatching a keydown event

https://reviewboard.mozilla.org/r/78972/#review77768
Attachment #8791563 - Flags: review?(m_kato) → review+
Comment on attachment 8791564 [details]
Bug 1300003 part.2 Don't continue to dispatch eKeyPress event at handling WM_KEYDOWN or following WM_CHAR messages if focused window is changed during dispatching an event

https://reviewboard.mozilla.org/r/78974/#review78284
Attachment #8791564 - Flags: review?(m_kato) → review+
Comment on attachment 8791565 [details]
Bug 1300003 part.3 NativeKey::GetFollowingCharMessage() should always remove following WM_CHAR message

https://reviewboard.mozilla.org/r/78976/#review78298
Attachment #8791565 - Flags: review?(m_kato) → review+
Comment on attachment 8791566 [details]
Bug 1300003 part.4 Remove NativeKey::mIsFollowedByNonControlCharMessage because calling NativeKey::IsFollowedByNonControlCharMessage() is enough fast

https://reviewboard.mozilla.org/r/78978/#review78300
Attachment #8791566 - Flags: review?(m_kato) → review+
Comment on attachment 8791567 [details]
Bug 1300003 part.5 Remove odd WM_CHAR messages which are caused by ATOK or WXG (both of them are Japanese IME)

https://reviewboard.mozilla.org/r/78980/#review78364
Attachment #8791567 - Flags: review?(m_kato) → review+
Comment on attachment 8791568 [details]
Bug 1300003 part.6 NativeKey shouldn't try to dispatch plugin events for removed char messages when mWidget won't dispatch plugin events

https://reviewboard.mozilla.org/r/78982/#review78374
Attachment #8791568 - Flags: review?(m_kato) → review+
Pushed by masayuki@d-toybox.com:
https://hg.mozilla.org/integration/autoland/rev/1c503e563219
part.1 NativeKey should remove following char messages before dispatching a keydown event r=m_kato
https://hg.mozilla.org/integration/autoland/rev/bf88f2c838e2
part.2 Don't continue to dispatch eKeyPress event at handling WM_KEYDOWN or following WM_CHAR messages if focused window is changed during dispatching an event r=m_kato
https://hg.mozilla.org/integration/autoland/rev/e4426fbaff8e
part.3 NativeKey::GetFollowingCharMessage() should always remove following WM_CHAR message r=m_kato
https://hg.mozilla.org/integration/autoland/rev/4eb2eab93848
part.4 Remove NativeKey::mIsFollowedByNonControlCharMessage because calling NativeKey::IsFollowedByNonControlCharMessage() is enough fast r=m_kato
https://hg.mozilla.org/integration/autoland/rev/4364160065bc
part.5 Remove odd WM_CHAR messages which are caused by ATOK or WXG (both of them are Japanese IME) r=m_kato
https://hg.mozilla.org/integration/autoland/rev/949fe298aefd
part.6 NativeKey shouldn't try to dispatch plugin events for removed char messages when mWidget won't dispatch plugin events r=m_kato
Mark 51 as fix-optional. If it's worth uplift to 51, feel free to nominate it.
Depends on: 1305943
Depends on: 1394112
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: