fix extenderModifiers for OSX
Keys other than modifiers cannot be accessed outside
of non key related events from NSApplication. adding
a local monitor allows to catch the keys we need
during the delay duration.
Try to handle all modifiers from localMonitor
Apply modifiers already pressed on focusIn events macos
We now request a copy of keydown and modifier change
events to set the proper flags as background application
BUG:372646
BUG:373299
BUG:391088
(cherry picked from commit 4b9fa0c85e8f4cf9412ad01dd073c4a83ac7ea67)