| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_APP_KEYSTONE_GLUE_H_ | 5 #ifndef CHROME_APP_KEYSTONE_GLUE_H_ |
| 6 #define CHROME_APP_KEYSTONE_GLUE_H_ | 6 #define CHROME_APP_KEYSTONE_GLUE_H_ |
| 7 | 7 |
| 8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
| 9 #import <base/scoped_nsobject.h> | 9 #import <base/scoped_nsobject.h> |
| 10 | 10 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 // -checkForUpdate launches a check for updates, and -installUpdate begins | 79 // -checkForUpdate launches a check for updates, and -installUpdate begins |
| 80 // installing an available update. For each, status will be communicated via | 80 // installing an available update. For each, status will be communicated via |
| 81 // a kAutoupdateStatusNotification notification, and will also be available | 81 // a kAutoupdateStatusNotification notification, and will also be available |
| 82 // through -recentNotification. | 82 // through -recentNotification. |
| 83 - (void)checkForUpdate; | 83 - (void)checkForUpdate; |
| 84 - (void)installUpdate; | 84 - (void)installUpdate; |
| 85 | 85 |
| 86 // Accessor for recentNotification_. Returns an autoreleased NSNotification. | 86 // Accessor for recentNotification_. Returns an autoreleased NSNotification. |
| 87 - (NSNotification*)recentNotification; | 87 - (NSNotification*)recentNotification; |
| 88 | 88 |
| 89 // Clears the saved recentNotification_. | |
| 90 - (void)clearRecentNotification; | |
| 91 | |
| 92 // Accessor for the kAutoupdateStatusStatus field of recentNotification_'s | 89 // Accessor for the kAutoupdateStatusStatus field of recentNotification_'s |
| 93 // userInfo dictionary. | 90 // userInfo dictionary. |
| 94 - (AutoupdateStatus)recentStatus; | 91 - (AutoupdateStatus)recentStatus; |
| 95 | 92 |
| 96 // Returns YES if an asynchronous operation is pending: if an update check or | 93 // Returns YES if an asynchronous operation is pending: if an update check or |
| 97 // installation attempt is currently in progress. | 94 // installation attempt is currently in progress. |
| 98 - (BOOL)asyncOperationPending; | 95 - (BOOL)asyncOperationPending; |
| 99 | 96 |
| 100 @end // @interface KeystoneGlue | 97 @end // @interface KeystoneGlue |
| 101 | 98 |
| 102 @interface KeystoneGlue(ExposedForTesting) | 99 @interface KeystoneGlue(ExposedForTesting) |
| 103 | 100 |
| 104 // Release the shared instance. Use this in tests to reset the shared | |
| 105 // instance in case strange things are done to it for testing purposes. Never | |
| 106 // call this from non-test code. | |
| 107 + (void)releaseDefaultKeystoneGlue; | |
| 108 | |
| 109 // Load any params we need for configuring Keystone. | 101 // Load any params we need for configuring Keystone. |
| 110 - (void)loadParameters; | 102 - (void)loadParameters; |
| 111 | 103 |
| 112 // Load the Keystone registration object. | 104 // Load the Keystone registration object. |
| 113 // Return NO on failure. | 105 // Return NO on failure. |
| 114 - (BOOL)loadKeystoneRegistration; | 106 - (BOOL)loadKeystoneRegistration; |
| 115 | 107 |
| 116 - (void)stopTimer; | 108 - (void)stopTimer; |
| 117 | 109 |
| 118 // Called when a checkForUpdate: notification completes. | 110 // Called when a checkForUpdate: notification completes. |
| 119 - (void)checkForUpdateComplete:(NSNotification*)notification; | 111 - (void)checkForUpdateComplete:(NSNotification*)notification; |
| 120 | 112 |
| 121 // Called when an installUpdate: notification completes. | 113 // Called when an installUpdate: notification completes. |
| 122 - (void)installUpdateComplete:(NSNotification*)notification; | 114 - (void)installUpdateComplete:(NSNotification*)notification; |
| 123 | 115 |
| 124 @end // @interface KeystoneGlue(ExposedForTesting) | 116 @end // @interface KeystoneGlue(ExposedForTesting) |
| 125 | 117 |
| 126 #endif // CHROME_APP_KEYSTONE_GLUE_H_ | 118 #endif // CHROME_APP_KEYSTONE_GLUE_H_ |
| OLD | NEW |