Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Side by Side Diff: remoting/host/host_details.cc

Issue 1863933002: [remoting android] Add and build host code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@android-host-add-native
Patch Set: Add resources_android.cc Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « remoting/host/disconnect_window_android.cc ('k') | remoting/host/input_injector_android.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "remoting/host/host_details.h" 5 #include "remoting/host/host_details.h"
6 6
7 #include "base/sys_info.h" 7 #include "base/sys_info.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #if defined(OS_LINUX) 10 #if defined(OS_LINUX)
11 #include "base/linux_util.h" 11 #include "base/linux_util.h"
12 #endif 12 #endif
13 13
14 namespace remoting { 14 namespace remoting {
15 15
16 // Get the host Operating System Name, removing the need to check for OS 16 // Get the host Operating System Name, removing the need to check for OS
17 // definitions and keeps the keys used consistant. 17 // definitions and keeps the keys used consistant.
18 std::string GetHostOperatingSystemName() { 18 std::string GetHostOperatingSystemName() {
19 #if defined(OS_WIN) 19 #if defined(OS_WIN)
20 return "Windows"; 20 return "Windows";
21 #elif defined(OS_MACOSX) 21 #elif defined(OS_MACOSX)
22 return "Mac"; 22 return "Mac";
23 #elif defined(OS_CHROMEOS) 23 #elif defined(OS_CHROMEOS)
24 return "ChromeOS"; 24 return "ChromeOS";
25 #elif defined(OS_LINUX) 25 #elif defined(OS_LINUX)
26 return "Linux"; 26 return "Linux";
27 #elif defined(OS_ANDROID)
28 return "Android";
29 #else
30 #error "Unsupported host OS"
27 #endif 31 #endif
28 } 32 }
29 33
30 // Get the host Operating System Version, removing the need to check for OS 34 // Get the host Operating System Version, removing the need to check for OS
31 // definitions and keeps the format used consistant. 35 // definitions and keeps the format used consistant.
32 std::string GetHostOperatingSystemVersion() { 36 std::string GetHostOperatingSystemVersion() {
33 #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_CHROMEOS) 37 #if defined(OS_LINUX)
38 return base::GetLinuxDistro();
39 #else
34 return base::SysInfo::OperatingSystemVersion(); 40 return base::SysInfo::OperatingSystemVersion();
35 #elif defined(OS_LINUX)
36 return base::GetLinuxDistro();
37 #endif 41 #endif
38 } 42 }
39 43
40 } // namespace remoting 44 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/disconnect_window_android.cc ('k') | remoting/host/input_injector_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698