Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(640)

Side by Side Diff: chrome/browser/lifetime/application_lifetime.h

Issue 12096060: browser: Start moving application_lifetime.h functions into chrome namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #ifndef CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_ 5 #ifndef CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_
6 #define CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_ 6 #define CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_
7 7
8 namespace browser { 8 namespace browser {
9 9
10 // Starts a user initiated exit process. Called from Browser::Exit. 10 // Starts a user initiated exit process. Called from Browser::Exit.
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 #endif 47 #endif
48 48
49 // Closes all browsers. If the session is ending the windows are closed 49 // Closes all browsers. If the session is ending the windows are closed
50 // directly. Otherwise the windows are closed by way of posting a WM_CLOSE 50 // directly. Otherwise the windows are closed by way of posting a WM_CLOSE
51 // message. 51 // message.
52 void CloseAllBrowsers(); 52 void CloseAllBrowsers();
53 53
54 // Begins shutdown of the application when the desktop session is ending. 54 // Begins shutdown of the application when the desktop session is ending.
55 void SessionEnding(); 55 void SessionEnding();
56 56
57 } // namespace browser
58
59 namespace chrome {
60
57 // Tells the BrowserList to keep the application alive after the last Browser 61 // Tells the BrowserList to keep the application alive after the last Browser
58 // closes. This is implemented as a count, so callers should pair their calls 62 // closes. This is implemented as a count, so callers should pair their calls
59 // to StartKeepAlive() with matching calls to EndKeepAlive() when they no 63 // to StartKeepAlive() with matching calls to EndKeepAlive() when they no
60 // longer need to keep the application running. 64 // longer need to keep the application running.
61 void StartKeepAlive(); 65 void StartKeepAlive();
62 66
63 // Stops keeping the application alive after the last Browser is closed. 67 // Stops keeping the application alive after the last Browser is closed.
64 // Should match a previous call to StartKeepAlive(). 68 // Should match a previous call to StartKeepAlive().
65 void EndKeepAlive(); 69 void EndKeepAlive();
66 70
67 // Returns true if application will continue running after the last Browser 71 // Returns true if application will continue running after the last Browser
68 // closes. 72 // closes.
69 bool WillKeepAlive(); 73 bool WillKeepAlive();
70 74
71 // Emits APP_TERMINATING notification. It is guaranteed that the 75 // Emits APP_TERMINATING notification. It is guaranteed that the
72 // notification is sent only once. 76 // notification is sent only once.
73 void NotifyAppTerminating(); 77 void NotifyAppTerminating();
74 78
75 // Send out notifications. 79 // Send out notifications.
76 // For ChromeOS, also request session manager to end the session. 80 // For ChromeOS, also request session manager to end the session.
77 void NotifyAndTerminate(bool fast_path); 81 void NotifyAndTerminate(bool fast_path);
78 82
79 // Called once the application is exiting. 83 // Called once the application is exiting.
80 void OnAppExiting(); 84 void OnAppExiting();
81 85
82 // Called once the application is exiting to do any platform specific 86 // Called once the application is exiting to do any platform specific
83 // processing required. 87 // processing required.
84 void HandleAppExitingForPlatform(); 88 void HandleAppExitingForPlatform();
85 89
86 } // namespace browser 90 } // namespace chrome
87 91
88 #endif // CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_ 92 #endif // CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_application_mac.mm ('k') | chrome/browser/lifetime/application_lifetime.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698