| 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 "chromecast/base/cast_sys_info_android.h" | 5 #include "chromecast/base/cast_sys_info_android.h" |
| 6 | 6 |
| 7 #include "base/android/build_info.h" | 7 #include "base/android/build_info.h" |
| 8 #include "base/android/jni_android.h" | 8 #include "base/android/jni_android.h" |
| 9 #include "base/android/jni_string.h" | 9 #include "base/android/jni_string.h" |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| 11 #include "base/strings/string_number_conversions.h" | 11 #include "base/strings/string_number_conversions.h" |
| 12 #include "base/sys_info.h" | 12 #include "base/sys_info.h" |
| 13 #include "chromecast/base/cast_sys_info_util.h" | 13 #include "chromecast/base/cast_sys_info_util.h" |
| 14 #include "chromecast/base/version.h" | 14 #include "chromecast/base/version.h" |
| 15 #include "jni/CastSysInfoAndroid_jni.h" | 15 #include "jni/CastSysInfoAndroid_jni.h" |
| 16 | 16 |
| 17 namespace chromecast { | 17 namespace chromecast { |
| 18 | 18 |
| 19 namespace { | 19 namespace { |
| 20 const char kBuildTypeUser[] = "user"; | 20 const char kBuildTypeUser[] = "user"; |
| 21 } // namespace | 21 } // namespace |
| 22 | 22 |
| 23 // static | 23 // static |
| 24 std::unique_ptr<CastSysInfo> CreateSysInfo() { | 24 std::unique_ptr<CastSysInfo> CreateSysInfo() { |
| 25 return base::WrapUnique(new CastSysInfoAndroid()); | 25 return base::MakeUnique<CastSysInfoAndroid>(); |
| 26 } | 26 } |
| 27 | 27 |
| 28 CastSysInfoAndroid::CastSysInfoAndroid() | 28 CastSysInfoAndroid::CastSysInfoAndroid() |
| 29 : build_info_(base::android::BuildInfo::GetInstance()) { | 29 : build_info_(base::android::BuildInfo::GetInstance()) { |
| 30 } | 30 } |
| 31 | 31 |
| 32 CastSysInfoAndroid::~CastSysInfoAndroid() { | 32 CastSysInfoAndroid::~CastSysInfoAndroid() { |
| 33 } | 33 } |
| 34 | 34 |
| 35 CastSysInfo::BuildType CastSysInfoAndroid::GetBuildType() { | 35 CastSysInfo::BuildType CastSysInfoAndroid::GetBuildType() { |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 NOTREACHED() << "GL information shouldn't be requested on Android."; | 114 NOTREACHED() << "GL information shouldn't be requested on Android."; |
| 115 return ""; | 115 return ""; |
| 116 } | 116 } |
| 117 | 117 |
| 118 std::string CastSysInfoAndroid::GetGlVersion() { | 118 std::string CastSysInfoAndroid::GetGlVersion() { |
| 119 NOTREACHED() << "GL information shouldn't be requested on Android."; | 119 NOTREACHED() << "GL information shouldn't be requested on Android."; |
| 120 return ""; | 120 return ""; |
| 121 } | 121 } |
| 122 | 122 |
| 123 } // namespace chromecast | 123 } // namespace chromecast |
| OLD | NEW |