OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/metrics/ui/screen_info_metrics_provider.h" | 5 #include "components/metrics/ui/screen_info_metrics_provider.h" |
6 | 6 |
| 7 #include "build/build_config.h" |
7 #include "components/metrics/proto/system_profile.pb.h" | 8 #include "components/metrics/proto/system_profile.pb.h" |
8 #include "ui/gfx/screen.h" | 9 #include "ui/gfx/screen.h" |
9 | 10 |
10 namespace metrics { | 11 namespace metrics { |
11 | 12 |
12 #if defined(OS_WIN) | 13 #if defined(OS_WIN) |
13 | 14 |
14 #include <windows.h> | 15 #include <windows.h> |
15 | 16 |
16 namespace { | 17 namespace { |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 return gfx::Screen::GetNativeScreen()-> | 85 return gfx::Screen::GetNativeScreen()-> |
85 GetPrimaryDisplay().device_scale_factor(); | 86 GetPrimaryDisplay().device_scale_factor(); |
86 } | 87 } |
87 | 88 |
88 int ScreenInfoMetricsProvider::GetScreenCount() const { | 89 int ScreenInfoMetricsProvider::GetScreenCount() const { |
89 // TODO(scottmg): NativeScreen maybe wrong. http://crbug.com/133312 | 90 // TODO(scottmg): NativeScreen maybe wrong. http://crbug.com/133312 |
90 return gfx::Screen::GetNativeScreen()->GetNumDisplays(); | 91 return gfx::Screen::GetNativeScreen()->GetNumDisplays(); |
91 } | 92 } |
92 | 93 |
93 } // namespace metrics | 94 } // namespace metrics |
OLD | NEW |