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

Side by Side Diff: chrome/common/chrome_version_info.cc

Issue 93793010: Update uses of UTF conversions in chrome/common to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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 | Annotate | Revision Log
« no previous file with comments | « chrome/common/child_process_logging_win.cc ('k') | chrome/common/content_settings_helper.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 (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/common/chrome_version_info.h" 5 #include "chrome/common/chrome_version_info.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/file_version_info.h" 8 #include "base/file_version_info.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "base/threading/thread_restrictions.h" 10 #include "base/threading/thread_restrictions.h"
(...skipping 24 matching lines...) Expand all
35 VersionInfo::~VersionInfo() { 35 VersionInfo::~VersionInfo() {
36 } 36 }
37 37
38 bool VersionInfo::is_valid() const { 38 bool VersionInfo::is_valid() const {
39 return version_info_.get() != NULL; 39 return version_info_.get() != NULL;
40 } 40 }
41 41
42 std::string VersionInfo::Name() const { 42 std::string VersionInfo::Name() const {
43 if (!is_valid()) 43 if (!is_valid())
44 return std::string(); 44 return std::string();
45 return UTF16ToUTF8(version_info_->product_name()); 45 return base::UTF16ToUTF8(version_info_->product_name());
46 } 46 }
47 47
48 std::string VersionInfo::Version() const { 48 std::string VersionInfo::Version() const {
49 if (!is_valid()) 49 if (!is_valid())
50 return std::string(); 50 return std::string();
51 return UTF16ToUTF8(version_info_->product_version()); 51 return base::UTF16ToUTF8(version_info_->product_version());
52 } 52 }
53 53
54 std::string VersionInfo::LastChange() const { 54 std::string VersionInfo::LastChange() const {
55 if (!is_valid()) 55 if (!is_valid())
56 return std::string(); 56 return std::string();
57 return UTF16ToUTF8(version_info_->last_change()); 57 return base::UTF16ToUTF8(version_info_->last_change());
58 } 58 }
59 59
60 bool VersionInfo::IsOfficialBuild() const { 60 bool VersionInfo::IsOfficialBuild() const {
61 if (!is_valid()) 61 if (!is_valid())
62 return false; 62 return false;
63 return version_info_->is_official_build(); 63 return version_info_->is_official_build();
64 } 64 }
65 65
66 #elif defined(OS_POSIX) 66 #elif defined(OS_POSIX)
67 // We get chrome version information from chrome_version_info_posix.h, 67 // We get chrome version information from chrome_version_info_posix.h,
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 #elif defined(OS_OPENBSD) 137 #elif defined(OS_OPENBSD)
138 return "OpenBSD"; 138 return "OpenBSD";
139 #elif defined(OS_SOLARIS) 139 #elif defined(OS_SOLARIS)
140 return "Solaris"; 140 return "Solaris";
141 #else 141 #else
142 return "Unknown"; 142 return "Unknown";
143 #endif 143 #endif
144 } 144 }
145 145
146 } // namespace chrome 146 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/common/child_process_logging_win.cc ('k') | chrome/common/content_settings_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698