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

Side by Side Diff: chrome/install_static/install_modes.cc

Issue 2491463002: Revert of Windows install_static refactor. (Closed)
Patch Set: Created 4 years, 1 month 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 | « chrome/install_static/install_modes.h ('k') | chrome/install_static/install_modes_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/install_static/install_modes.h"
6
7 namespace install_static {
8
9 namespace {
10
11 std::wstring GetUnregisteredKeyPathForProduct(const wchar_t* product) {
12 return std::wstring(L"Software\\").append(product);
13 }
14
15 std::wstring GetClientStateKeyPathForApp(const wchar_t* app_guid) {
16 return std::wstring(L"Software\\Google\\Update\\ClientState\\")
17 .append(app_guid);
18 }
19
20 std::wstring GetClientStateMediumKeyPathForApp(const wchar_t* app_guid) {
21 return std::wstring(L"Software\\Google\\Update\\ClientStateMedium\\")
22 .append(app_guid);
23 }
24
25 } // namespace
26
27 std::wstring GetClientStateKeyPath(const wchar_t* app_guid) {
28 if (!kUseGoogleUpdateIntegration)
29 return GetUnregisteredKeyPathForProduct(kProductPathName);
30 return GetClientStateKeyPathForApp(app_guid);
31 }
32
33 std::wstring GetBinariesClientStateKeyPath() {
34 if (!kUseGoogleUpdateIntegration)
35 return GetUnregisteredKeyPathForProduct(kBinariesPathName);
36 return GetClientStateKeyPathForApp(kBinariesAppGuid);
37 }
38
39 std::wstring GetClientStateMediumKeyPath(const wchar_t* app_guid) {
40 if (!kUseGoogleUpdateIntegration)
41 return GetUnregisteredKeyPathForProduct(kProductPathName);
42 return GetClientStateMediumKeyPathForApp(app_guid);
43 }
44
45 std::wstring GetBinariesClientStateMediumKeyPath() {
46 if (!kUseGoogleUpdateIntegration)
47 return GetUnregisteredKeyPathForProduct(kBinariesPathName);
48 return GetClientStateMediumKeyPathForApp(kBinariesAppGuid);
49 }
50
51 } // namespace install_static
OLDNEW
« no previous file with comments | « chrome/install_static/install_modes.h ('k') | chrome/install_static/install_modes_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698