WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
201632
[Win][WK2] Pressing space key on text input form scrolls the page
https://bugs.webkit.org/show_bug.cgi?id=201632
Summary
[Win][WK2] Pressing space key on text input form scrolls the page
Fujii Hironori
Reported
2019-09-09 22:22:12 PDT
Created
attachment 378442
[details]
test case [Win][WK2] Pressing space key sometimes inputs space character, but scrolling the page otherwise 1. Start Windows WK2 MiniBrowser 2. Open test page 3. Hitting space key repeatedly Expected: space characters should be input consistently Actual: Sometimes page scrolling happens.
Attachments
test case
(107 bytes, text/html)
2019-09-09 22:22 PDT
,
Fujii Hironori
no flags
Details
test case
(130 bytes, text/html)
2019-09-10 19:47 PDT
,
Fujii Hironori
no flags
Details
Patch
(2.27 KB, patch)
2020-01-20 22:29 PST
,
Fujii Hironori
ross.kirsling
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Fujii Hironori
Comment 1
2019-09-09 22:26:13 PDT
It seems that the current implementation of WebPage::performDefaultBehaviorForKeyEvent is wrong. Current implementation:
https://trac.webkit.org/browser/webkit/trunk/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp?rev=244932#L70
Original implementation:
https://trac.webkit.org/browser/webkit/trunk/Source/WebKit2/WebProcess/WebPage/win/WebPageWin.cpp?rev=138331#L201
Fujii Hironori
Comment 2
2019-09-10 19:47:44 PDT
Created
attachment 378532
[details]
test case
Fujii Hironori
Comment 3
2019-09-10 19:48:41 PDT
scrolling happens every time.
Fujii Hironori
Comment 4
2019-09-10 23:15:43 PDT
In Windows, key events are mapped as following: WM_KEYDOWN → WebEvent::RawKeyDown WM_KEYUP → WebEvent::KeyUp WM_CHAR → WebEvent::Char On the other hand, other ports are using only two types: WebEvent::KeyDown WebEvent::KeyUp
Fujii Hironori
Comment 5
2019-09-10 23:19:44 PDT
In GTK port, WebEvent::KeyDown are converted to keydown and keypress DOM events. And, keypress event are comsumed in WebEditorClient::handleKeyboardEvent. Then, WebPage::performDefaultBehaviorForKeyEvent is not called because it is consumed.
Fujii Hironori
Comment 6
2019-09-11 01:01:19 PDT
See also:
Bug 56612
– Web page shouldn't swallow alt-key combinations on Windows
Bug 43665
– Delete key doesn't go Back in WebKit2 windows
Fujii Hironori
Comment 7
2020-01-20 21:02:57 PST
After I implemented the logic preventing keypress event if the preceding keydown event is canceled, space characters can't be input anymore in WinCairo WK2.
Bug 204694
– [Win] Retrieve all following WM_CHAR events at the beginning of processing WM_KEYDOWN event
Fujii Hironori
Comment 8
2020-01-20 22:29:46 PST
Created
attachment 388280
[details]
Patch
Fujii Hironori
Comment 9
2020-01-21 17:56:22 PST
Committed
r254897
: <
https://trac.webkit.org/changeset/254897
>
Radar WebKit Bug Importer
Comment 10
2020-01-21 17:57:12 PST
<
rdar://problem/58781952
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug