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

Unified Diff: chrome/app/keystone_glue.h

Issue 339010: Make the About box display existing pending operations instead of firing off a new update check (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/app/keystone_glue.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/app/keystone_glue.h
===================================================================
--- chrome/app/keystone_glue.h (revision 30078)
+++ chrome/app/keystone_glue.h (working copy)
@@ -11,10 +11,14 @@
// Possible outcomes of -checkForUpdate and -installUpdate. A version may
// accompany some of these, but beware: a version is never required. For
// statuses that can be accompanied by a version, the comment indicates what
-// version is referenced.
+// version is referenced. A notification posted containing an asynchronous
+// status will always be followed by a notification with a terminal status.
enum AutoupdateStatus {
- kAutoupdateCurrent = 0, // version of the running application
+ kAutoupdateNone = 0, // no version (initial state only)
+ kAutoupdateChecking, // no version (asynchronous operation in progress)
+ kAutoupdateCurrent, // version of the running application
kAutoupdateAvailable, // version of the update that is available
+ kAutoupdateInstalling, // no version (asynchronous operation in progress)
kAutoupdateInstalled, // version of the update that was installed
kAutoupdateCheckFailed, // no version
kAutoupdateInstallFailed // no version
@@ -75,7 +79,7 @@
// -checkForUpdate launches a check for updates, and -installUpdate begins
// installing an available update. For each, status will be communicated via
// a kAutoupdateStatusNotification notification, and will also be available
-// through -recentUpdateStatus.
+// through -recentNotification.
- (void)checkForUpdate;
- (void)installUpdate;
@@ -85,6 +89,14 @@
// Clears the saved recentNotification_.
- (void)clearRecentNotification;
+// Accessor for the kAutoupdateStatusStatus field of recentNotification_'s
+// userInfo dictionary.
+- (AutoupdateStatus)recentStatus;
+
+// Returns YES if an asynchronous operation is pending: if an update check or
+// installation attempt is currently in progress.
+- (BOOL)asyncOperationPending;
+
@end // @interface KeystoneGlue
@interface KeystoneGlue(ExposedForTesting)
« no previous file with comments | « no previous file | chrome/app/keystone_glue.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698