| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 2334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2345 // BrowserPluginEmbedder. Thus, this code will not be executed if a | 2345 // BrowserPluginEmbedder. Thus, this code will not be executed if a |
| 2346 // BrowserPluginEmbedder exists for this WebContents. | 2346 // BrowserPluginEmbedder exists for this WebContents. |
| 2347 CHECK(!browser_plugin_embedder_.get()); | 2347 CHECK(!browser_plugin_embedder_.get()); |
| 2348 browser_plugin_embedder_.reset( | 2348 browser_plugin_embedder_.reset( |
| 2349 BrowserPluginEmbedder::Create(this, GetRenderViewHost())); | 2349 BrowserPluginEmbedder::Create(this, GetRenderViewHost())); |
| 2350 browser_plugin_embedder_->CreateGuest(GetRenderViewHost(), | 2350 browser_plugin_embedder_->CreateGuest(GetRenderViewHost(), |
| 2351 instance_id, | 2351 instance_id, |
| 2352 params); | 2352 params); |
| 2353 } | 2353 } |
| 2354 | 2354 |
| 2355 void WebContentsImpl::DidBlock3DAPIs(const GURL& url, |
| 2356 ThreeDAPIType requester) { |
| 2357 FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
| 2358 DidBlock3DAPIs(url, requester)); |
| 2359 } |
| 2360 |
| 2355 // Notifies the RenderWidgetHost instance about the fact that the page is | 2361 // Notifies the RenderWidgetHost instance about the fact that the page is |
| 2356 // loading, or done loading and calls the base implementation. | 2362 // loading, or done loading and calls the base implementation. |
| 2357 void WebContentsImpl::SetIsLoading(bool is_loading, | 2363 void WebContentsImpl::SetIsLoading(bool is_loading, |
| 2358 LoadNotificationDetails* details) { | 2364 LoadNotificationDetails* details) { |
| 2359 if (is_loading == is_loading_) | 2365 if (is_loading == is_loading_) |
| 2360 return; | 2366 return; |
| 2361 | 2367 |
| 2362 if (!is_loading) { | 2368 if (!is_loading) { |
| 2363 load_state_ = net::LoadStateWithParam(net::LOAD_STATE_IDLE, string16()); | 2369 load_state_ = net::LoadStateWithParam(net::LOAD_STATE_IDLE, string16()); |
| 2364 load_state_host_.clear(); | 2370 load_state_host_.clear(); |
| (...skipping 972 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3337 | 3343 |
| 3338 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { | 3344 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { |
| 3339 return browser_plugin_guest_.get(); | 3345 return browser_plugin_guest_.get(); |
| 3340 } | 3346 } |
| 3341 | 3347 |
| 3342 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { | 3348 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { |
| 3343 return browser_plugin_embedder_.get(); | 3349 return browser_plugin_embedder_.get(); |
| 3344 } | 3350 } |
| 3345 | 3351 |
| 3346 } // namespace content | 3352 } // namespace content |
| OLD | NEW |