| OLD | NEW |
| 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 // NOTE: This code is a legacy utility API for partners to check whether | 5 // NOTE: This code is a legacy utility API for partners to check whether |
| 6 // Chrome can be installed and launched. Recent updates are being made | 6 // Chrome can be installed and launched. Recent updates are being made |
| 7 // to add new functionality. These updates use code from Chromium, the old | 7 // to add new functionality. These updates use code from Chromium, the old |
| 8 // coded against the win32 api directly. If you have an itch to shave a | 8 // coded against the win32 api directly. If you have an itch to shave a |
| 9 // yak, feel free to re-write the old code too. | 9 // yak, feel free to re-write the old code too. |
| 10 | 10 |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 using base::win::ScopedHandle; | 51 using base::win::ScopedHandle; |
| 52 | 52 |
| 53 namespace { | 53 namespace { |
| 54 | 54 |
| 55 const wchar_t kChromeRegClientsKey[] = | 55 const wchar_t kChromeRegClientsKey[] = |
| 56 L"Software\\Google\\Update\\Clients\\" | 56 L"Software\\Google\\Update\\Clients\\" |
| 57 L"{8A69D345-D564-463c-AFF1-A69D9E530F96}"; | 57 L"{8A69D345-D564-463c-AFF1-A69D9E530F96}"; |
| 58 const wchar_t kChromeRegClientStateKey[] = | 58 const wchar_t kChromeRegClientStateKey[] = |
| 59 L"Software\\Google\\Update\\ClientState\\" | 59 L"Software\\Google\\Update\\ClientState\\" |
| 60 L"{8A69D345-D564-463c-AFF1-A69D9E530F96}"; | 60 L"{8A69D345-D564-463c-AFF1-A69D9E530F96}"; |
| 61 const wchar_t kChromeRegClientStateMediumKey[] = | |
| 62 L"Software\\Google\\Update\\ClientStateMedium\\" | |
| 63 L"{8A69D345-D564-463c-AFF1-A69D9E530F96}"; | |
| 64 | 61 |
| 65 const wchar_t kGCAPITempKey[] = L"Software\\Google\\GCAPITemp"; | 62 const wchar_t kGCAPITempKey[] = L"Software\\Google\\GCAPITemp"; |
| 66 | 63 |
| 67 const wchar_t kChromeRegLaunchCmd[] = L"InstallerSuccessLaunchCmdLine"; | |
| 68 const wchar_t kChromeRegLastLaunchCmd[] = L"LastInstallerSuccessLaunchCmdLine"; | |
| 69 const wchar_t kChromeRegVersion[] = L"pv"; | 64 const wchar_t kChromeRegVersion[] = L"pv"; |
| 70 const wchar_t kNoChromeOfferUntil[] = | 65 const wchar_t kNoChromeOfferUntil[] = |
| 71 L"SOFTWARE\\Google\\No Chrome Offer Until"; | 66 L"SOFTWARE\\Google\\No Chrome Offer Until"; |
| 72 | 67 |
| 73 const wchar_t kC1FPendingKey[] = | 68 const wchar_t kC1FPendingKey[] = |
| 74 L"Software\\Google\\Common\\Rlz\\Events\\C"; | 69 L"Software\\Google\\Common\\Rlz\\Events\\C"; |
| 75 const wchar_t kC1FSentKey[] = | 70 const wchar_t kC1FSentKey[] = |
| 76 L"Software\\Google\\Common\\Rlz\\StatefulEvents\\C"; | 71 L"Software\\Google\\Common\\Rlz\\StatefulEvents\\C"; |
| 77 const wchar_t kC1FKey[] = L"C1F"; | 72 const wchar_t kC1FKey[] = L"C1F"; |
| 78 | 73 |
| (...skipping 710 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 789 key.WriteValue(kRelaunchAllowedAfterValue, | 784 key.WriteValue(kRelaunchAllowedAfterValue, |
| 790 FormatDateOffsetByMonths(6)) != ERROR_SUCCESS || | 785 FormatDateOffsetByMonths(6)) != ERROR_SUCCESS || |
| 791 !SetRelaunchExperimentLabels(relaunch_brandcode, shell_mode)) { | 786 !SetRelaunchExperimentLabels(relaunch_brandcode, shell_mode)) { |
| 792 if (error_code) | 787 if (error_code) |
| 793 *error_code = RELAUNCH_ERROR_RELAUNCH_FAILED; | 788 *error_code = RELAUNCH_ERROR_RELAUNCH_FAILED; |
| 794 return FALSE; | 789 return FALSE; |
| 795 } | 790 } |
| 796 | 791 |
| 797 return TRUE; | 792 return TRUE; |
| 798 } | 793 } |
| OLD | NEW |