diff --git a/AppKit/CPApplication.j b/AppKit/CPApplication.j index b10113d28..b57c26a98 100644 --- a/AppKit/CPApplication.j +++ b/AppKit/CPApplication.j @@ -576,27 +576,33 @@ CPRunContinuesResponse = -1002; { _currentEvent = anEvent; +#if PLATFORM(DOM) var willPropagate = [[[anEvent window] platformWindow] _willPropagateCurrentDOMEvent]; // temporarily pretend we won't propagate the event. we'll restore the saved value later // we do this outside the if so that changes user code might make in _handleKeyEquiv. are preserved [[[anEvent window] platformWindow] _propagateCurrentDOMEvent:NO]; +#endif // Check if this is a candidate for key equivalent... if ([anEvent _couldBeKeyEquivalent] && [self _handleKeyEquivalent:anEvent]) { +#if PLATFORM(DOM) var characters = [anEvent characters], modifierFlags = [anEvent modifierFlags]; // Unconditionally propagate on these keys to solve browser copy paste bugs if ((characters == "c" || characters == "x" || characters == "v") && (modifierFlags & CPPlatformActionKeyMask)) [[[anEvent window] platformWindow] _propagateCurrentDOMEvent:YES]; +#endif return; } +#if PLATFORM(DOM) // if we make it this far, then restore the original willPropagate value [[[anEvent window] platformWindow] _propagateCurrentDOMEvent:willPropagate]; +#endif if (_eventListeners.length) {