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 "base/sys_info.h" | 5 #include "base/sys_info.h" |
6 | 6 |
7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
10 #include "base/metrics/field_trial.h" | 10 #include "base/metrics/field_trial.h" |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 std::string SysInfo::HardwareModelName() { | 52 std::string SysInfo::HardwareModelName() { |
53 return std::string(); | 53 return std::string(); |
54 } | 54 } |
55 #endif | 55 #endif |
56 | 56 |
57 // static | 57 // static |
58 base::TimeDelta SysInfo::Uptime() { | 58 base::TimeDelta SysInfo::Uptime() { |
59 // This code relies on an implementation detail of TimeTicks::Now() - that | 59 // This code relies on an implementation detail of TimeTicks::Now() - that |
60 // its return value happens to coincide with the system uptime value in | 60 // its return value happens to coincide with the system uptime value in |
61 // microseconds, on Win/Mac/iOS/Linux/ChromeOS and Android. | 61 // microseconds, on Win/Mac/iOS/Linux/ChromeOS and Android. |
62 int64 uptime_in_microseconds = TimeTicks::Now().ToInternalValue(); | 62 int64_t uptime_in_microseconds = TimeTicks::Now().ToInternalValue(); |
63 return base::TimeDelta::FromMicroseconds(uptime_in_microseconds); | 63 return base::TimeDelta::FromMicroseconds(uptime_in_microseconds); |
64 } | 64 } |
65 | 65 |
66 } // namespace base | 66 } // namespace base |
OLD | NEW |