Home | History | Annotate | Download | only in first_run
      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.
      4 
      5 #ifndef CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_
      6 #define CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_
      7 #pragma once
      8 
      9 class CommandLine;
     10 
     11 namespace upgrade_util {
     12 
     13 // If the new_chrome.exe exists (placed by the installer then is swapped
     14 // to chrome.exe and the old chrome is renamed to old_chrome.exe. If there
     15 // is no new_chrome.exe or the swap fails the return is false;
     16 bool SwapNewChromeExeIfPresent();
     17 
     18 // Combines the two methods, RelaunchChromeBrowser and
     19 // SwapNewChromeExeIfPresent, to perform the rename and relaunch of
     20 // the browser. Note that relaunch does NOT exit the existing browser process.
     21 // If this is called before message loop is executed, simply exit the main
     22 // function. If browser is already running, you will need to exit it.
     23 bool DoUpgradeTasks(const CommandLine& command_line);
     24 
     25 }  // namespace upgrade_util
     26 
     27 #endif  // CHROME_BROWSER_FIRST_RUN_UPGRADE_UTIL_WIN_H_
     28