OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/renderer_host/render_widget_host.h" | 5 #include "chrome/browser/renderer_host/render_widget_host.h" |
6 | 6 |
7 #include "app/keyboard_codes.h" | 7 #include "app/keyboard_codes.h" |
8 #include "base/auto_reset.h" | 8 #include "base/auto_reset.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 if (routing_id_ == MSG_ROUTING_NONE) | 94 if (routing_id_ == MSG_ROUTING_NONE) |
95 routing_id_ = process_->GetNextRoutingID(); | 95 routing_id_ = process_->GetNextRoutingID(); |
96 | 96 |
97 process_->Attach(this, routing_id_); | 97 process_->Attach(this, routing_id_); |
98 // Because the widget initializes as is_hidden_ == false, | 98 // Because the widget initializes as is_hidden_ == false, |
99 // tell the process host that we're alive. | 99 // tell the process host that we're alive. |
100 process_->WidgetRestored(); | 100 process_->WidgetRestored(); |
101 | 101 |
102 if (CommandLine::ForCurrentProcess()->HasSwitch( | 102 if (CommandLine::ForCurrentProcess()->HasSwitch( |
103 switches::kForceRendererAccessibility) || | 103 switches::kForceRendererAccessibility) || |
104 Singleton<BrowserAccessibilityState>()->IsAccessibleBrowser()) { | 104 BrowserAccessibilityState::GetInstance()->IsAccessibleBrowser()) { |
105 EnableRendererAccessibility(); | 105 EnableRendererAccessibility(); |
106 } | 106 } |
107 } | 107 } |
108 | 108 |
109 RenderWidgetHost::~RenderWidgetHost() { | 109 RenderWidgetHost::~RenderWidgetHost() { |
110 // Clear our current or cached backing store if either remains. | 110 // Clear our current or cached backing store if either remains. |
111 BackingStoreManager::RemoveBackingStore(this); | 111 BackingStoreManager::RemoveBackingStore(this); |
112 | 112 |
113 process_->Release(routing_id_); | 113 process_->Release(routing_id_); |
114 } | 114 } |
(...skipping 1116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1231 return; | 1231 return; |
1232 | 1232 |
1233 for (int i = 0; i < static_cast<int>(deferred_plugin_handles_.size()); i++) { | 1233 for (int i = 0; i < static_cast<int>(deferred_plugin_handles_.size()); i++) { |
1234 #if defined(TOOLKIT_USES_GTK) | 1234 #if defined(TOOLKIT_USES_GTK) |
1235 view_->CreatePluginContainer(deferred_plugin_handles_[i]); | 1235 view_->CreatePluginContainer(deferred_plugin_handles_[i]); |
1236 #endif | 1236 #endif |
1237 } | 1237 } |
1238 | 1238 |
1239 deferred_plugin_handles_.clear(); | 1239 deferred_plugin_handles_.clear(); |
1240 } | 1240 } |
OLD | NEW |