getModifierState() should support for modifiers: - https://w3c.github.io/uievents/#dom-keyboardevent-getmodifierstate In particular, we are missing the following ones: CapsLock, Fn, FnLock, Hyper, NumLock, Super, ScrollLock, Symbol, SymbolLock.
The only one that is missing and that seems to make sense on Mac is capsLock.
Created attachment 290734 [details] Patch
Created attachment 290735 [details] Patch
Why doesn’t Fn make sense on Mac?
A good test case with Fn might be the return key with the "Fn" modifier down.
(In reply to comment #4) > Why doesn’t Fn make sense on Mac? As far as I can tell, this is a hardware key, it does not generate an NSEvent. Note that there is no ModifierFlag for Fn key on NSEvent: - https://developer.apple.com/reference/appkit/nsevent/modifier_flags
Created attachment 290741 [details] Patch
Created attachment 290743 [details] Patch
Comment on attachment 290743 [details] Patch Clearing flags on attachment: 290743 Committed r206828: <http://trac.webkit.org/changeset/206828>
All reviewed patches have been landed. Closing bug.