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/plugin/plugin_thread.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/plugin/plugin_thread.cc')
-rw-r--r-- | chrome/plugin/plugin_thread.cc | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/chrome/plugin/plugin_thread.cc b/chrome/plugin/plugin_thread.cc index fb24e3f..e74e95e 100644 --- a/chrome/plugin/plugin_thread.cc +++ b/chrome/plugin/plugin_thread.cc @@ -135,10 +135,6 @@ void PluginThread::OnControlMessageReceived(const IPC::Message& msg) { IPC_MESSAGE_HANDLER(PluginProcessMsg_PluginMessage, OnPluginMessage) IPC_MESSAGE_HANDLER(PluginProcessMsg_NotifyRenderersOfPendingShutdown, OnNotifyRenderersOfPendingShutdown) -#if defined(OS_MACOSX) - IPC_MESSAGE_HANDLER(PluginProcessMsg_PluginFocusNotify, - OnPluginFocusNotify) -#endif IPC_END_MESSAGE_MAP() } @@ -177,21 +173,6 @@ void PluginThread::OnNotifyRenderersOfPendingShutdown() { PluginChannel::NotifyRenderersOfPendingShutdown(); } -#if defined(OS_MACOSX) -void PluginThread::OnPluginFocusNotify(uint32 instance_id) { - WebPluginDelegateImpl* focused_instance = - reinterpret_cast<WebPluginDelegateImpl*>(instance_id); - std::set<WebPluginDelegateImpl*> active_delegates = - WebPluginDelegateImpl::GetActiveDelegates(); - for (std::set<WebPluginDelegateImpl*>::iterator iter = - active_delegates.begin(); - iter != active_delegates.end(); iter++) { - WebPluginDelegateImpl* instance = *iter; - instance->FocusChanged(instance == focused_instance); - } -} -#endif - namespace webkit_glue { #if defined(OS_WIN) |