Chromium Code Reviews| 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/common/chrome_constants_util_win.h" | |
| 6 | |
| 7 #include "chrome/installer/util/browser_distribution.h" | |
|
grt (UTC plus 2)
2016/02/04 15:52:30
common_constants doesn't depend on installer_util,
gab
2016/03/07 21:53:55
Good catch, I think it's reasonable to add the dep
grt (UTC plus 2)
2016/03/08 15:44:47
I'm concerned about making a "constants" target pu
gab
2016/03/09 20:29:35
Fair enough. Thought of naming these chrome_paths_
grt (UTC plus 2)
2016/03/10 19:14:42
Huh. Here's what is currently used by chrome.exe f
| |
| 8 | |
| 9 namespace { | |
| 10 | |
| 11 base::string16 GetSuffixedRegistryPath(const wchar_t* suffix) { | |
| 12 BrowserDistribution* chrome_distribution = | |
|
grt (UTC plus 2)
2016/02/04 15:52:30
DCHECK_EQ(L'\\', *suffix);
gab
2016/03/07 21:53:55
Done.
| |
| 13 BrowserDistribution::GetDistribution(); | |
| 14 DCHECK(chrome_distribution); | |
| 15 DCHECK_EQ(BrowserDistribution::CHROME_BROWSER, | |
| 16 chrome_distribution->GetType()); | |
| 17 return chrome_distribution->GetRegistryPath() + suffix; | |
|
grt (UTC plus 2)
2016/02/04 15:52:30
DCHECK_NE(L'\\', the last char of GetRegistryPath(
gab
2016/03/07 21:53:55
Done.
| |
| 18 } | |
| 19 | |
| 20 } // namespace | |
| 21 | |
| 22 base::string16 GetBrowserCrashDumpAttemptsRegistryPath() { | |
| 23 return GetSuffixedRegistryPath(L"\\BrowserCrashDumpAttempts"); | |
| 24 } | |
| 25 | |
| 26 base::string16 GetBrowserExitCodesRegistryPath() { | |
| 27 return GetSuffixedRegistryPath(L"\\BrowserExitCodes"); | |
| 28 } | |
| OLD | NEW |