Don't show supervised user as "already on this device" while they're being imported.
[chromium-blink-merge.git] / chrome / browser / first_run / upgrade_util_win.h
blobc67e1d0cc032a88b14deca5e767b449bbebe137b
1 // Copyright (c) 2011 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.
5 #ifndef CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_
6 #define CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_
8 namespace base {
9 class CommandLine;
12 namespace upgrade_util {
14 // If the new_chrome.exe exists (placed by the installer then is swapped
15 // to chrome.exe and the old chrome is renamed to old_chrome.exe. If there
16 // is no new_chrome.exe or the swap fails the return is false;
17 bool SwapNewChromeExeIfPresent();
19 // Returns true if the currently running chrome.exe has been renamed to
20 // old_chrome.exe. This means that the running executable is out of date and
21 // has been renamed by the in-use update process. old_chrome.exe shouldn't
22 // continue on and run as the browser process since it may end up launching
23 // newer chrome.exes as child processes resulting in a version mismatch.
24 bool IsRunningOldChrome();
26 // Combines the two methods, RelaunchChromeBrowser and
27 // SwapNewChromeExeIfPresent, to perform the rename and relaunch of
28 // the browser. Note that relaunch does NOT exit the existing browser process.
29 // If this is called before message loop is executed, simply exit the main
30 // function. If browser is already running, you will need to exit it.
31 bool DoUpgradeTasks(const base::CommandLine& command_line);
33 } // namespace upgrade_util
35 #endif // CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_