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

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

Issue 176363002: Rename Start/EndKeepAlive to Increment/DecrementKeepAliveCount (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 9
10 class Browser; 10 class Browser;
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // directly. Otherwise the windows are closed by way of posting a WM_CLOSE 76 // directly. Otherwise the windows are closed by way of posting a WM_CLOSE
77 // message. This will quit the application if there is nothing other than 77 // message. This will quit the application if there is nothing other than
78 // browser windows keeping it alive or the application is quitting. 78 // browser windows keeping it alive or the application is quitting.
79 void CloseAllBrowsers(); 79 void CloseAllBrowsers();
80 80
81 // Begins shutdown of the application when the desktop session is ending. 81 // Begins shutdown of the application when the desktop session is ending.
82 void SessionEnding(); 82 void SessionEnding();
83 83
84 // Tells the BrowserList to keep the application alive after the last Browser 84 // Tells the BrowserList to keep the application alive after the last Browser
85 // closes. This is implemented as a count, so callers should pair their calls 85 // closes. This is implemented as a count, so callers should pair their calls
86 // to StartKeepAlive() with matching calls to EndKeepAlive() when they no 86 // to IncrementKeepAliveCount() with matching calls to DecrementKeepAliveCount()
87 // when they no
miket_OOO 2014/02/24 16:41:32 nit wrap
87 // longer need to keep the application running. 88 // longer need to keep the application running.
88 void StartKeepAlive(); 89 void IncrementKeepAliveCount();
89 90
90 // Stops keeping the application alive after the last Browser is closed. 91 // Stops keeping the application alive after the last Browser is closed.
91 // Should match a previous call to StartKeepAlive(). 92 // Should match a previous call to IncrementKeepAliveCount().
92 void EndKeepAlive(); 93 void DecrementKeepAliveCount();
93 94
94 // Returns true if application will continue running after the last Browser 95 // Returns true if application will continue running after the last Browser
95 // closes. 96 // closes.
96 bool WillKeepAlive(); 97 bool WillKeepAlive();
97 98
98 // Emits APP_TERMINATING notification. It is guaranteed that the 99 // Emits APP_TERMINATING notification. It is guaranteed that the
99 // notification is sent only once. 100 // notification is sent only once.
100 void NotifyAppTerminating(); 101 void NotifyAppTerminating();
101 102
102 // Send out notifications. 103 // Send out notifications.
103 // For ChromeOS, also request session manager to end the session. 104 // For ChromeOS, also request session manager to end the session.
104 void NotifyAndTerminate(bool fast_path); 105 void NotifyAndTerminate(bool fast_path);
105 106
106 // Called once the application is exiting. 107 // Called once the application is exiting.
107 void OnAppExiting(); 108 void OnAppExiting();
108 109
109 // Called once the application is exiting to do any platform specific 110 // Called once the application is exiting to do any platform specific
110 // processing required. 111 // processing required.
111 void HandleAppExitingForPlatform(); 112 void HandleAppExitingForPlatform();
112 113
113 // Returns true if we can start the shutdown sequence for the browser, i.e. the 114 // Returns true if we can start the shutdown sequence for the browser, i.e. the
114 // last browser window is being closed. 115 // last browser window is being closed.
115 bool ShouldStartShutdown(Browser* browser); 116 bool ShouldStartShutdown(Browser* browser);
116 117
117 } // namespace chrome 118 } // namespace chrome
118 119
119 #endif // CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_ 120 #endif // CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_
OLDNEW
« no previous file with comments | « chrome/browser/devtools/devtools_sanity_browsertest.cc ('k') | chrome/browser/lifetime/application_lifetime.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698