summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/views')
-rw-r--r--chrome/browser/views/tab_contents_container_view.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/chrome/browser/views/tab_contents_container_view.cc b/chrome/browser/views/tab_contents_container_view.cc
index cfcb301..2fb25a1 100644
--- a/chrome/browser/views/tab_contents_container_view.cc
+++ b/chrome/browser/views/tab_contents_container_view.cc
@@ -227,11 +227,15 @@ void TabContentsContainerView::RemoveObservers() {
void TabContentsContainerView::RenderViewHostChanged(RenderViewHost* old_host,
RenderViewHost* new_host) {
- if (old_host && old_host->view())
- FocusManager::UninstallFocusSubclass(old_host->view()->GetPluginHWND());
+ if (old_host && old_host->view()) {
+ FocusManager::UninstallFocusSubclass(
+ old_host->view()->GetPluginNativeView());
+ }
- if (new_host && new_host->view())
- FocusManager::InstallFocusSubclass(new_host->view()->GetPluginHWND(), this);
+ if (new_host && new_host->view()) {
+ FocusManager::InstallFocusSubclass(
+ new_host->view()->GetPluginNativeView(), this);
+ }
// If we are focused, we need to pass the focus to the new RenderViewHost.
FocusManager* focus_manager =