diff options
author | stuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-05 23:10:31 +0000 |
---|---|---|
committer | stuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-05 23:10:31 +0000 |
commit | 7d3c02c0eaf7d4cf7becfe869c6b4030ded6293a (patch) | |
tree | 83cb9e4813a07021c771e625d036a5d0a9188dfe /chrome/browser/plugin_process_host_mac.cc | |
parent | f3692bc59a04276845ae33f0d2e98f4738b38525 (diff) | |
download | chromium_src-7d3c02c0eaf7d4cf7becfe869c6b4030ded6293a.zip chromium_src-7d3c02c0eaf7d4cf7becfe869c6b4030ded6293a.tar.gz chromium_src-7d3c02c0eaf7d4cf7becfe869c6b4030ded6293a.tar.bz2 |
Update Mac plugins for SetFocus changes, and remove old workaround messages
Now that WebKit is sending unfocus events, rework Mac plugins to correctly track plugin focus as a function of WebKit element focus and window-level view focus. Remove message plumbing for the old workarounds that were used to partially simulate focus switching for Mac plugins.
Windows and Linux will currently ignore the new focus loss notifications so their behavior is unchanged.
BUG=32721
TEST=Mac plugins should stop reacting to keyboard events once another control on the page, or the omnibox, is focused. They should also regain keyboard focus when switching back to their tab if they had it when the tab was hidden.
Review URL: http://codereview.chromium.org/1736007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46516 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/plugin_process_host_mac.cc')
-rw-r--r-- | chrome/browser/plugin_process_host_mac.cc | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/chrome/browser/plugin_process_host_mac.cc b/chrome/browser/plugin_process_host_mac.cc index 86bfe9f..716ab81 100644 --- a/chrome/browser/plugin_process_host_mac.cc +++ b/chrome/browser/plugin_process_host_mac.cc @@ -100,19 +100,6 @@ void PluginProcessHost::OnAppActivation() { } } -void PluginProcessHost::OnPluginReceivedFocus(int process_id, int instance_id) { - DCHECK(ChromeThread::CurrentlyOn(ChromeThread::IO)); - // A plugin has received keyboard focus, so tell all other plugin processes - // that they no longer have it (simulating the OS-level focus notifications - // that Gtk and Windows provide). - for (ChildProcessHost::Iterator iter(ChildProcessInfo::PLUGIN_PROCESS); - !iter.Done(); ++iter) { - PluginProcessHost* plugin = static_cast<PluginProcessHost*>(*iter); - int instance = (plugin->handle() == process_id) ? instance_id : 0; - plugin->Send(new PluginProcessMsg_PluginFocusNotify(instance)); - } -} - void PluginProcessHost::OnPluginSetCursorVisibility(bool visible) { if (plugin_cursor_visible_ != visible) { plugin_cursor_visible_ = visible; |