diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-14 04:38:38 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-14 04:38:38 +0000 |
commit | 835d7c811c98f179090c57a827a9c9baa2130435 (patch) | |
tree | edcff6b2c9029c6f867f650d762837f2485d99fb /webkit/glue | |
parent | 4b1deac7ba7e7a6bf0425e6ed4db26e0c29daa7f (diff) | |
download | chromium_src-835d7c811c98f179090c57a827a9c9baa2130435.zip chromium_src-835d7c811c98f179090c57a827a9c9baa2130435.tar.gz chromium_src-835d7c811c98f179090c57a827a9c9baa2130435.tar.bz2 |
Move Stats, histograms, and field trial into a metrics subdirectory of base and
put them in the base namespace.
TEST=it compiles
BUG=none
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62510 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r-- | webkit/glue/plugins/pepper_plugin_instance.cc | 2 | ||||
-rw-r--r-- | webkit/glue/plugins/plugin_lib.cc | 10 | ||||
-rw-r--r-- | webkit/glue/plugins/webplugin_delegate_impl.cc | 3 | ||||
-rw-r--r-- | webkit/glue/plugins/webplugin_delegate_impl_gtk.cc | 10 | ||||
-rw-r--r-- | webkit/glue/plugins/webplugin_delegate_impl_mac.mm | 6 | ||||
-rw-r--r-- | webkit/glue/plugins/webplugin_delegate_impl_win.cc | 6 | ||||
-rw-r--r-- | webkit/glue/plugins/webview_plugin.cc | 2 | ||||
-rw-r--r-- | webkit/glue/site_isolation_metrics.cc | 2 | ||||
-rw-r--r-- | webkit/glue/webkitclient_impl.cc | 6 |
9 files changed, 23 insertions, 24 deletions
diff --git a/webkit/glue/plugins/pepper_plugin_instance.cc b/webkit/glue/plugins/pepper_plugin_instance.cc index c051fff..30c4fb3 100644 --- a/webkit/glue/plugins/pepper_plugin_instance.cc +++ b/webkit/glue/plugins/pepper_plugin_instance.cc @@ -5,7 +5,7 @@ #include "webkit/glue/plugins/pepper_plugin_instance.h" #include "base/logging.h" -#include "base/histogram.h" +#include "base/metrics/histogram.h" #if defined(OS_MACOSX) #include "base/mac_util.h" #include "base/scoped_cftyperef.h" diff --git a/webkit/glue/plugins/plugin_lib.cc b/webkit/glue/plugins/plugin_lib.cc index 9a0770e..6c95274 100644 --- a/webkit/glue/plugins/plugin_lib.cc +++ b/webkit/glue/plugins/plugin_lib.cc @@ -6,7 +6,7 @@ #include "base/logging.h" #include "base/message_loop.h" -#include "base/stats_counters.h" +#include "base/metrics/stats_counters.h" #include "base/string_util.h" #include "webkit/glue/webkit_glue.h" #include "webkit/glue/plugins/plugin_instance.h" @@ -72,7 +72,7 @@ PluginLib::PluginLib(const WebPluginInfo& info, saved_data_(0), instance_count_(0), skip_unload_(false) { - StatsCounter(kPluginLibrariesLoadedCounter).Increment(); + base::StatsCounter(kPluginLibrariesLoadedCounter).Increment(); memset(static_cast<void*>(&plugin_funcs_), 0, sizeof(plugin_funcs_)); g_loaded_libs->push_back(this); @@ -87,7 +87,7 @@ PluginLib::PluginLib(const WebPluginInfo& info, } PluginLib::~PluginLib() { - StatsCounter(kPluginLibrariesLoadedCounter).Decrement(); + base::StatsCounter(kPluginLibrariesLoadedCounter).Decrement(); if (saved_data_ != 0) { // TODO - delete the savedData object here } @@ -143,13 +143,13 @@ void PluginLib::PreventLibraryUnload() { PluginInstance* PluginLib::CreateInstance(const std::string& mime_type) { PluginInstance* new_instance = new PluginInstance(this, mime_type); instance_count_++; - StatsCounter(kPluginInstancesActiveCounter).Increment(); + base::StatsCounter(kPluginInstancesActiveCounter).Increment(); DCHECK_NE(static_cast<PluginInstance*>(NULL), new_instance); return new_instance; } void PluginLib::CloseInstance() { - StatsCounter(kPluginInstancesActiveCounter).Decrement(); + base::StatsCounter(kPluginInstancesActiveCounter).Decrement(); instance_count_--; // If a plugin is running in its own process it will get unloaded on process // shutdown. diff --git a/webkit/glue/plugins/webplugin_delegate_impl.cc b/webkit/glue/plugins/webplugin_delegate_impl.cc index 53745466..c54bbc8 100644 --- a/webkit/glue/plugins/webplugin_delegate_impl.cc +++ b/webkit/glue/plugins/webplugin_delegate_impl.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2010 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -11,7 +11,6 @@ #include "base/message_loop.h" #include "base/process_util.h" #include "base/scoped_ptr.h" -#include "base/stats_counters.h" #include "base/string_util.h" #include "third_party/WebKit/WebKit/chromium/public/WebInputEvent.h" #include "webkit/glue/plugins/plugin_constants_win.h" diff --git a/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc b/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc index 3d112fa..bceda0e 100644 --- a/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc +++ b/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc @@ -14,7 +14,7 @@ #include "base/file_util.h" #include "base/message_loop.h" #include "base/process_util.h" -#include "base/stats_counters.h" +#include "base/metrics/stats_counters.h" #include "base/string_util.h" #include "gfx/blit.h" #include "skia/ext/platform_canvas.h" @@ -443,8 +443,8 @@ void WebPluginDelegateImpl::WindowlessPaint(cairo_t* context, } // Tell the plugin to paint into the pixmap. - static StatsRate plugin_paint("Plugin.Paint"); - StatsScope<StatsRate> scope(plugin_paint); + static base::StatsRate plugin_paint("Plugin.Paint"); + base::StatsScope<base::StatsRate> scope(plugin_paint); NPError err = instance()->NPP_HandleEvent(&np_event); DCHECK_EQ(err, NPERR_NO_ERROR); @@ -474,8 +474,8 @@ void WebPluginDelegateImpl::WindowlessPaint(cairo_t* context, event.drawable = GDK_PIXMAP_XID(pixmap_); // Tell the plugin to paint into the pixmap. - static StatsRate plugin_paint("Plugin.Paint"); - StatsScope<StatsRate> scope(plugin_paint); + static base::StatsRate plugin_paint("Plugin.Paint"); + base::StatsScope<base::StatsRate> scope(plugin_paint); NPError err = instance()->NPP_HandleEvent(&np_event); DCHECK_EQ(err, NPERR_NO_ERROR); diff --git a/webkit/glue/plugins/webplugin_delegate_impl_mac.mm b/webkit/glue/plugins/webplugin_delegate_impl_mac.mm index 11d244c..b7e7702 100644 --- a/webkit/glue/plugins/webplugin_delegate_impl_mac.mm +++ b/webkit/glue/plugins/webplugin_delegate_impl_mac.mm @@ -13,8 +13,8 @@ #include "base/file_util.h" #include "base/message_loop.h" +#include "base/metrics/stats_counters.h" #include "base/scoped_ptr.h" -#include "base/stats_counters.h" #include "base/string_util.h" #include "base/utf_string_conversions.h" #include "third_party/WebKit/WebKit/chromium/public/WebInputEvent.h" @@ -650,8 +650,8 @@ void WebPluginDelegateImpl::WindowlessPaint(gfx::NativeDrawingContext context, return; DCHECK(buffer_context_ == context); - static StatsRate plugin_paint("Plugin.Paint"); - StatsScope<StatsRate> scope(plugin_paint); + static base::StatsRate plugin_paint("Plugin.Paint"); + base::StatsScope<base::StatsRate> scope(plugin_paint); // Plugin invalidates trigger asynchronous paints with the original // invalidation rect; the plugin may be resized before the paint is handled, diff --git a/webkit/glue/plugins/webplugin_delegate_impl_win.cc b/webkit/glue/plugins/webplugin_delegate_impl_win.cc index 2a10775..c9500d1 100644 --- a/webkit/glue/plugins/webplugin_delegate_impl_win.cc +++ b/webkit/glue/plugins/webplugin_delegate_impl_win.cc @@ -12,9 +12,9 @@ #include "base/iat_patch.h" #include "base/lazy_instance.h" #include "base/message_loop.h" +#include "base/metrics/stats_counters.h" #include "base/registry.h" #include "base/scoped_ptr.h" -#include "base/stats_counters.h" #include "base/string_number_conversions.h" #include "base/string_split.h" #include "base/string_util.h" @@ -1029,8 +1029,8 @@ void WebPluginDelegateImpl::WindowlessPaint(HDC hdc, // NOTE: NPAPI is not 64bit safe. It puts pointers into 32bit values. paint_event.wParam = PtrToUlong(hdc); paint_event.lParam = PtrToUlong(&damage_rect_win); - static StatsRate plugin_paint("Plugin.Paint"); - StatsScope<StatsRate> scope(plugin_paint); + static base::StatsRate plugin_paint("Plugin.Paint"); + base::StatsScope<base::StatsRate> scope(plugin_paint); instance()->NPP_HandleEvent(&paint_event); window_.window = old_dc; } diff --git a/webkit/glue/plugins/webview_plugin.cc b/webkit/glue/plugins/webview_plugin.cc index 9287028..feb5720 100644 --- a/webkit/glue/plugins/webview_plugin.cc +++ b/webkit/glue/plugins/webview_plugin.cc @@ -4,8 +4,8 @@ #include "webkit/glue/plugins/webview_plugin.h" -#include "base/histogram.h" #include "base/message_loop.h" +#include "base/metrics/histogram.h" #include "third_party/WebKit/WebKit/chromium/public/WebCursorInfo.h" #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" #include "third_party/WebKit/WebKit/chromium/public/WebPluginContainer.h" diff --git a/webkit/glue/site_isolation_metrics.cc b/webkit/glue/site_isolation_metrics.cc index 912263f..58d8717 100644 --- a/webkit/glue/site_isolation_metrics.cc +++ b/webkit/glue/site_isolation_metrics.cc @@ -7,7 +7,7 @@ #include <set> #include "base/hash_tables.h" -#include "base/histogram.h" +#include "base/metrics/histogram.h" #include "net/base/mime_sniffer.h" #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" #include "third_party/WebKit/WebKit/chromium/public/WebSecurityOrigin.h" diff --git a/webkit/glue/webkitclient_impl.cc b/webkit/glue/webkitclient_impl.cc index e9b05f1..648f3bd5 100644 --- a/webkit/glue/webkitclient_impl.cc +++ b/webkit/glue/webkitclient_impl.cc @@ -14,10 +14,10 @@ #include "base/lock.h" #include "base/message_loop.h" +#include "base/metrics/stats_counters.h" #include "base/process_util.h" #include "base/platform_file.h" #include "base/singleton.h" -#include "base/stats_counters.h" #include "base/string_number_conversions.h" #include "base/string_util.h" #include "base/time.h" @@ -217,11 +217,11 @@ void WebKitClientImpl::getPluginList(bool refresh, } void WebKitClientImpl::decrementStatsCounter(const char* name) { - StatsCounter(name).Decrement(); + base::StatsCounter(name).Decrement(); } void WebKitClientImpl::incrementStatsCounter(const char* name) { - StatsCounter(name).Increment(); + base::StatsCounter(name).Increment(); } void WebKitClientImpl::traceEventBegin(const char* name, void* id, |