| 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 2324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2335 // BrowserPluginEmbedder. Thus, this code will not be executed if a | 2335 // BrowserPluginEmbedder. Thus, this code will not be executed if a |
| 2336 // BrowserPluginEmbedder exists for this WebContents. | 2336 // BrowserPluginEmbedder exists for this WebContents. |
| 2337 CHECK(!browser_plugin_embedder_.get()); | 2337 CHECK(!browser_plugin_embedder_.get()); |
| 2338 browser_plugin_embedder_.reset( | 2338 browser_plugin_embedder_.reset( |
| 2339 BrowserPluginEmbedder::Create(this, GetRenderViewHost())); | 2339 BrowserPluginEmbedder::Create(this, GetRenderViewHost())); |
| 2340 browser_plugin_embedder_->CreateGuest(GetRenderViewHost(), | 2340 browser_plugin_embedder_->CreateGuest(GetRenderViewHost(), |
| 2341 instance_id, | 2341 instance_id, |
| 2342 params); | 2342 params); |
| 2343 } | 2343 } |
| 2344 | 2344 |
| 2345 void WebContentsImpl::DidBlock3DAPIs(const GURL& url, |
| 2346 ThreeDAPIType requester) { |
| 2347 FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
| 2348 DidBlock3DAPIs(url, requester)); |
| 2349 } |
| 2350 |
| 2345 // Notifies the RenderWidgetHost instance about the fact that the page is | 2351 // Notifies the RenderWidgetHost instance about the fact that the page is |
| 2346 // loading, or done loading and calls the base implementation. | 2352 // loading, or done loading and calls the base implementation. |
| 2347 void WebContentsImpl::SetIsLoading(bool is_loading, | 2353 void WebContentsImpl::SetIsLoading(bool is_loading, |
| 2348 LoadNotificationDetails* details) { | 2354 LoadNotificationDetails* details) { |
| 2349 if (is_loading == is_loading_) | 2355 if (is_loading == is_loading_) |
| 2350 return; | 2356 return; |
| 2351 | 2357 |
| 2352 if (!is_loading) { | 2358 if (!is_loading) { |
| 2353 load_state_ = net::LoadStateWithParam(net::LOAD_STATE_IDLE, string16()); | 2359 load_state_ = net::LoadStateWithParam(net::LOAD_STATE_IDLE, string16()); |
| 2354 load_state_host_.clear(); | 2360 load_state_host_.clear(); |
| (...skipping 975 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3330 | 3336 |
| 3331 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { | 3337 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { |
| 3332 return browser_plugin_guest_.get(); | 3338 return browser_plugin_guest_.get(); |
| 3333 } | 3339 } |
| 3334 | 3340 |
| 3335 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { | 3341 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { |
| 3336 return browser_plugin_embedder_.get(); | 3342 return browser_plugin_embedder_.get(); |
| 3337 } | 3343 } |
| 3338 | 3344 |
| 3339 } // namespace content | 3345 } // namespace content |
| OLD | NEW |