mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-25 04:47:55 +00:00
Remove initializer taking SUHost from SUUserUpdaterDriver
This commit is contained in:
1 parent
48e0febf1a
commit
0bb5de196a
3 files changed
+8
-19
No files matched your search
Vendored
+4
@@ -9,6 +9,10 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import "SUUserUpdaterDriver.h"
|
||||
|
||||
@class SUHost;
|
||||
|
||||
@interface SUSparkleUserUpdaterDriver : NSObject <SUUserUpdaterDriver>
|
||||
|
||||
- (instancetype)initWithHost:(SUHost *)host;
|
||||
|
||||
@end
|
||||
Vendored
+1
-3
@@ -9,14 +9,12 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import "SUUpdateAlertChoice.h"
|
||||
|
||||
@class SUHost, SUUpdatePermissionPromptResult, SUAppcastItem;
|
||||
@class SUUpdatePermissionPromptResult, SUAppcastItem;
|
||||
|
||||
@protocol SUVersionDisplay;
|
||||
|
||||
@protocol SUUserUpdaterDriver <NSObject>
|
||||
|
||||
- (instancetype)initWithHost:(SUHost *)host;
|
||||
|
||||
#warning might need to whitelist class types for systemProfile.. need to test this
|
||||
- (void)requestUpdatePermissionWithSystemProfile:(NSArray *)systemProfile reply:(void (^)(SUUpdatePermissionPromptResult *))reply;
|
||||
|
||||
|
||||
@@ -11,25 +11,11 @@
|
||||
|
||||
#import "SUUserUpdaterDriver.h"
|
||||
|
||||
@interface SULoggerUpdateDriver : NSObject<SUUserUpdaterDriver>
|
||||
|
||||
@property (nonatomic, readonly) SUHost *host;
|
||||
|
||||
@interface SULoggerUpdateDriver : NSObject <SUUserUpdaterDriver>
|
||||
@end
|
||||
|
||||
@implementation SULoggerUpdateDriver
|
||||
|
||||
@synthesize host = _host;
|
||||
|
||||
- (instancetype)initWithHost:(SUHost *)host
|
||||
{
|
||||
self = [super init];
|
||||
if (self != nil) {
|
||||
_host = host;
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void)requestUpdatePermissionWithSystemProfile:(NSArray *)systemProfile reply:(void (^)(SUUpdatePermissionPromptResult *))reply
|
||||
{
|
||||
NSLog(@"Giving permission to automatically install updates!");
|
||||
@@ -132,7 +118,8 @@
|
||||
|
||||
- (void)windowDidLoad
|
||||
{
|
||||
self.updater.userUpdaterDriver = [[/* SUSparkleUserUpdaterDriver */ SULoggerUpdateDriver alloc] initWithHost:[[SUHost alloc] initWithBundle:[NSBundle mainBundle]]];
|
||||
//self.updater.userUpdaterDriver = [[SUSparkleUserUpdaterDriver alloc] initWithHost:[[SUHost alloc] initWithBundle:[NSBundle mainBundle]]];
|
||||
self.updater.userUpdaterDriver = [[SULoggerUpdateDriver alloc] init];
|
||||
}
|
||||
|
||||
- (NSString *)windowNibName
|
||||
|
||||
Reference in new issue
Block a user