[Webkit-unassigned] [Bug 183043] [WinCairo] Add WebKit Shared/win event files for wincairo webkit
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Mar 2 12:02:23 PST 2018
https://bugs.webkit.org/show_bug.cgi?id=183043
--- Comment #7 from Ryosuke Niwa <rniwa at webkit.org> ---
Comment on attachment 334862
--> https://bugs.webkit.org/attachment.cgi?id=334862
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=334862&action=review
r=me as an API owner as well.
> Source/WebKit/Shared/NativeWebWheelEvent.h:81
> + MSG m_nativeEvent;
You probably want to initialize MSG here.
> Source/WebKit/Shared/win/WebEventFactory.cpp:110
> + if (::GetKeyState(VK_MENU) & 0x8000)
Instead of keep having & 0x8000 everywhere,
can we add an inline helper function like IsKeyInDownState(VM_MENU) / IsKeyStateDown(::GetKeyState(VK_MENU))?
> Source/WebKit/Shared/win/WebEventFactory.cpp:123
> + if (::GetKeyState(VK_CONTROL) & 0x8000)
> + modifiers |= WebEvent::ControlKey;
> + if (::GetKeyState(VK_SHIFT) & 0x8000)
> + modifiers |= WebEvent::ShiftKey;
> + if (::GetKeyState(VK_MENU) & 0x8000)
> + modifiers |= WebEvent::AltKey;
Ditto about all these checks.
> Source/WebKit/Shared/win/WebEventFactory.cpp:456
> + WebEvent::Type type = keyboardEventTypeForEvent(message);
> + String text = textFromEvent(wparam, type);
> + String unmodifiedText = unmodifiedTextFromEvent(wparam, type);
> + String keyIdentifier = keyIdentifierFromEvent(wparam, type);
> + int windowsVirtualKeyCode = static_cast<int>(wparam);
> + int nativeVirtualKeyCode = static_cast<int>(wparam);
> + int macCharCode = 0;
> + bool autoRepeat = HIWORD(lparam) & KF_REPEAT;
> + bool isKeypad = isKeypadEvent(wparam, lparam, type);
> + bool isSystemKey = isSystemKeyEvent(message);
> + WebEvent::Modifiers modifiers = modifiersForCurrentKeyState();
Nit: Wrong indentation style. Never align assignment like this.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180302/da73aa9c/attachment.html>
More information about the webkit-unassigned
mailing list