summaryrefslogtreecommitdiffstats
path: root/chrome/browser/cocoa/chrome_event_processing_window.h
diff options
context:
space:
mode:
authorsuzhe@chromium.org <suzhe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-23 01:15:33 +0000
committersuzhe@chromium.org <suzhe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-23 01:15:33 +0000
commited8bf13bccd28196fa2e1ddd30dc98a100167919 (patch)
treee721a87554d87716db83adcbdcc6c1cdeb109f60 /chrome/browser/cocoa/chrome_event_processing_window.h
parent9febdb951b2a75ae69c2b2153c94ee5be86bb3ed (diff)
downloadchromium_src-ed8bf13bccd28196fa2e1ddd30dc98a100167919.zip
chromium_src-ed8bf13bccd28196fa2e1ddd30dc98a100167919.tar.gz
chromium_src-ed8bf13bccd28196fa2e1ddd30dc98a100167919.tar.bz2
Fix conflicts between accelerator keys and HTML DOM accesskeys.
This CL fixes conflicts between accelerator keys and HTML DOM accesskeys by suppressing Char events if corresponding RawKeyDown event was handled by the browser after returning from the renderer unhandled. This CL not only fixes this conflict issue, but also makes the behavior of handling accelerator keys similar than IE, which also suppresses a key press event if the key down event was handled as an accelerator key. BUG=21624 accesskey attributes conflict with browser shortcuts (like tab-switching) TEST=Open http://djmitche.github.com/buildbot/docs/0.7.11/ in one of opened multiple tabs, switch to another tab by pressing an alt-# key binding, then switch back to the original page to see if it's just as you left it before switching tabs. Review URL: http://codereview.chromium.org/235039 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@29857 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/chrome_event_processing_window.h')
-rw-r--r--chrome/browser/cocoa/chrome_event_processing_window.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/chrome/browser/cocoa/chrome_event_processing_window.h b/chrome/browser/cocoa/chrome_event_processing_window.h
index 59241b7..4f13c27 100644
--- a/chrome/browser/cocoa/chrome_event_processing_window.h
+++ b/chrome/browser/cocoa/chrome_event_processing_window.h
@@ -15,6 +15,7 @@
@interface ChromeEventProcessingWindow : NSWindow {
@private
BOOL redispatchingEvent_;
+ BOOL eventHandled_;
}
// Returns |YES| if |event| has been shortcircuited and should not be processed
@@ -25,7 +26,8 @@
// short-circuited to the RWHV. This is used to send keyboard events to the menu
// and the cmd-` handler if a keyboard event comes back unhandled from the
// renderer.
-- (void)redispatchEvent:(NSEvent*)event;
+// Returns |YES| if |event| has been handled.
+- (BOOL)redispatchEvent:(NSEvent*)event;
// See global_keyboard_shortcuts_mac.h for details on the next two functions.