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 "chrome/browser/metrics/metrics_log.h" | 5 #include "chrome/browser/metrics/metrics_log.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
257 | 257 |
258 WritePluginStabilityElements(plugin_list, pref); | 258 WritePluginStabilityElements(plugin_list, pref); |
259 } | 259 } |
260 } | 260 } |
261 | 261 |
262 PrefService* MetricsLog::GetPrefService() { | 262 PrefService* MetricsLog::GetPrefService() { |
263 return g_browser_process->local_state(); | 263 return g_browser_process->local_state(); |
264 } | 264 } |
265 | 265 |
266 gfx::Size MetricsLog::GetScreenSize() const { | 266 gfx::Size MetricsLog::GetScreenSize() const { |
267 return gfx::Screen::GetPrimaryMonitorSize(); | 267 return gfx::Screen::GetPrimaryMonitor().size(); |
268 } | 268 } |
269 | 269 |
270 int MetricsLog::GetScreenCount() const { | 270 int MetricsLog::GetScreenCount() const { |
271 return gfx::Screen::GetNumMonitors(); | 271 return gfx::Screen::GetNumMonitors(); |
272 } | 272 } |
273 | 273 |
274 | 274 |
275 void MetricsLog::GetFieldTrialIds( | 275 void MetricsLog::GetFieldTrialIds( |
276 std::vector<NameGroupId>* field_trial_ids) const { | 276 std::vector<NameGroupId>* field_trial_ids) const { |
277 base::FieldTrialList::GetFieldTrialNameGroupIds(field_trial_ids); | 277 base::FieldTrialList::GetFieldTrialNameGroupIds(field_trial_ids); |
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
839 i != log.result.end(); ++i) { | 839 i != log.result.end(); ++i) { |
840 OmniboxEventProto::Suggestion* suggestion = omnibox_event->add_suggestion(); | 840 OmniboxEventProto::Suggestion* suggestion = omnibox_event->add_suggestion(); |
841 suggestion->set_provider(AsOmniboxEventProviderType(i->provider)); | 841 suggestion->set_provider(AsOmniboxEventProviderType(i->provider)); |
842 suggestion->set_result_type(AsOmniboxEventResultType(i->type)); | 842 suggestion->set_result_type(AsOmniboxEventResultType(i->type)); |
843 suggestion->set_relevance(i->relevance); | 843 suggestion->set_relevance(i->relevance); |
844 suggestion->set_is_starred(i->starred); | 844 suggestion->set_is_starred(i->starred); |
845 } | 845 } |
846 | 846 |
847 ++num_events_; | 847 ++num_events_; |
848 } | 848 } |
OLD | NEW |