Refactor FirstRun class code into namespace first_run progressively. This cl refactors:
IsChromeFirstRun()
CreateSentinel()
RemoveSentinel()
GetFirstRunSentinelFilePath()
It also fixed an issue that chromeos first run won't create sentinel file, and the following runs always think it is a first run.
BUG=108137
TEST=None
Review URL: http://codereview.chromium.org/8989043
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@115925 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/chrome_browser_main_win.cc b/chrome/browser/chrome_browser_main_win.cc
index 3965c1d..246ff346 100644
--- a/chrome/browser/chrome_browser_main_win.cc
+++ b/chrome/browser/chrome_browser_main_win.cc
@@ -137,7 +137,7 @@
if (ret != chrome::RESULT_CODE_UNINSTALL_USER_CANCEL) {
// The following actions are just best effort.
VLOG(1) << "Executing uninstall actions";
- if (!FirstRun::RemoveSentinel())
+ if (!first_run::RemoveSentinel())
VLOG(1) << "Failed to delete sentinel file.";
// We want to remove user level shortcuts and we only care about the ones
// created by us and not by the installer so |alternate| is false.