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 void WebContentsImpl::OnSetSelectedColorInColorChooser(int color_chooser_id, | 2335 void WebContentsImpl::OnSetSelectedColorInColorChooser(int color_chooser_id, |
2336 SkColor color) { | 2336 SkColor color) { |
2337 if (color_chooser_ && | 2337 if (color_chooser_ && |
2338 color_chooser_id == color_chooser_->identifier()) | 2338 color_chooser_id == color_chooser_->identifier()) |
2339 color_chooser_->SetSelectedColor(color); | 2339 color_chooser_->SetSelectedColor(color); |
2340 } | 2340 } |
2341 | 2341 |
2342 void WebContentsImpl::OnPepperPluginHung(int plugin_child_id, | 2342 void WebContentsImpl::OnPepperPluginHung(int plugin_child_id, |
2343 const FilePath& path, | 2343 const FilePath& path, |
2344 bool is_hung) { | 2344 bool is_hung) { |
| 2345 UMA_HISTOGRAM_COUNTS("Pepper.PluginHung", 1); |
| 2346 |
2345 FOR_EACH_OBSERVER(WebContentsObserver, observers_, | 2347 FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
2346 PluginHungStatusChanged(plugin_child_id, path, is_hung)); | 2348 PluginHungStatusChanged(plugin_child_id, path, is_hung)); |
2347 } | 2349 } |
2348 | 2350 |
2349 // This exists for render views that don't have a WebUI, but do have WebUI | 2351 // This exists for render views that don't have a WebUI, but do have WebUI |
2350 // bindings enabled. | 2352 // bindings enabled. |
2351 void WebContentsImpl::OnWebUISend(const GURL& source_url, | 2353 void WebContentsImpl::OnWebUISend(const GURL& source_url, |
2352 const std::string& name, | 2354 const std::string& name, |
2353 const base::ListValue& args) { | 2355 const base::ListValue& args) { |
2354 if (delegate_) | 2356 if (delegate_) |
(...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3398 } | 3400 } |
3399 } | 3401 } |
3400 | 3402 |
3401 content::BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { | 3403 content::BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { |
3402 return browser_plugin_guest_.get(); | 3404 return browser_plugin_guest_.get(); |
3403 } | 3405 } |
3404 | 3406 |
3405 content::BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { | 3407 content::BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { |
3406 return browser_plugin_embedder_.get(); | 3408 return browser_plugin_embedder_.get(); |
3407 } | 3409 } |
OLD | NEW |