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 // Contains functions used by BrowserMain() that are win32-specific. | 5 // Contains functions used by BrowserMain() that are win32-specific. |
6 | 6 |
7 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ | 7 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ |
8 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ | 8 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ |
9 | 9 |
10 #include "base/files/file_path_watcher.h" | 10 #include "base/files/file_path_watcher.h" |
11 #include "chrome/browser/chrome_browser_main.h" | 11 #include "chrome/browser/chrome_browser_main.h" |
12 | 12 |
13 class DidRunUpdater; | 13 class DidRunUpdater; |
14 | 14 |
15 namespace base { | 15 namespace base { |
16 class CommandLine; | 16 class CommandLine; |
17 } | 17 } |
18 | 18 |
19 // Handle uninstallation when given the appropriate the command-line switch. | 19 // Handle uninstallation when given the appropriate the command-line switch. |
20 // If |chrome_still_running| is true a modal dialog will be shown asking the | 20 // If |chrome_still_running| is true a modal dialog will be shown asking the |
21 // user to close the other chrome instance. | 21 // user to close the other chrome instance. |
22 int DoUninstallTasks(bool chrome_still_running); | 22 int DoUninstallTasks(bool chrome_still_running); |
23 | 23 |
24 class ChromeBrowserMainPartsWin : public ChromeBrowserMainParts { | 24 class ChromeBrowserMainPartsWin : public ChromeBrowserMainParts { |
25 public: | 25 public: |
26 explicit ChromeBrowserMainPartsWin( | 26 explicit ChromeBrowserMainPartsWin( |
27 const content::MainFunctionParams& parameters); | 27 const content::MainFunctionParams& parameters); |
28 | 28 |
29 virtual ~ChromeBrowserMainPartsWin(); | 29 ~ChromeBrowserMainPartsWin() override; |
30 | 30 |
31 // BrowserParts overrides. | 31 // BrowserParts overrides. |
32 virtual void ToolkitInitialized() override; | 32 void ToolkitInitialized() override; |
33 virtual void PreMainMessageLoopStart() override; | 33 void PreMainMessageLoopStart() override; |
34 virtual int PreCreateThreads() override; | 34 int PreCreateThreads() override; |
35 | 35 |
36 // ChromeBrowserMainParts overrides. | 36 // ChromeBrowserMainParts overrides. |
37 virtual void ShowMissingLocaleMessageBox() override; | 37 void ShowMissingLocaleMessageBox() override; |
38 virtual void PostProfileInit() override; | 38 void PostProfileInit() override; |
39 virtual void PostBrowserStart() override; | 39 void PostBrowserStart() override; |
40 | 40 |
41 // Prepares the localized strings that are going to be displayed to | 41 // Prepares the localized strings that are going to be displayed to |
42 // the user if the browser process dies. These strings are stored in the | 42 // the user if the browser process dies. These strings are stored in the |
43 // environment block so they are accessible in the early stages of the | 43 // environment block so they are accessible in the early stages of the |
44 // chrome executable's lifetime. | 44 // chrome executable's lifetime. |
45 static void PrepareRestartOnCrashEnviroment( | 45 static void PrepareRestartOnCrashEnviroment( |
46 const base::CommandLine& parsed_command_line); | 46 const base::CommandLine& parsed_command_line); |
47 | 47 |
48 // Registers Chrome with the Windows Restart Manager, which will restore the | 48 // Registers Chrome with the Windows Restart Manager, which will restore the |
49 // Chrome session when the computer is restarted after a system update. | 49 // Chrome session when the computer is restarted after a system update. |
(...skipping 22 matching lines...) Expand all Loading... |
72 #endif | 72 #endif |
73 #if defined(KASKO) | 73 #if defined(KASKO) |
74 // Cleans up Kasko crash reports that exceeded the maximum upload attempts. | 74 // Cleans up Kasko crash reports that exceeded the maximum upload attempts. |
75 base::FilePathWatcher failed_kasko_crash_report_watcher_; | 75 base::FilePathWatcher failed_kasko_crash_report_watcher_; |
76 #endif | 76 #endif |
77 | 77 |
78 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainPartsWin); | 78 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainPartsWin); |
79 }; | 79 }; |
80 | 80 |
81 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ | 81 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_WIN_H_ |
OLD | NEW |