| OLD | NEW |
| (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 | |
| OLD | NEW |