Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 57 lines (45 sloc) 1.117 kB
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
1 //
2 // SUUpdateDriver.m
3 // Sparkle
4 //
5 // Created by Andy Matuschak on 5/7/08.
6 // Copyright 2008 Andy Matuschak. All rights reserved.
7 //
8
9 #import "SUUpdateDriver.h"
43a0a7d @uliwitness Merge of changes from SVN repository:
uliwitness authored
10 #import "SUHost.h"
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
11
d7774c0 performed a code review, specifically:
Sean McBride authored
12 NSString * const SUUpdateDriverFinishedNotification = @"SUUpdateDriverFinished";
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
13
14 @implementation SUUpdateDriver
7b39268 @andymatuschak No longer fragile-ly using class method singletons to get to the upda…
andymatuschak authored
15 - initWithUpdater:(SUUpdater *)anUpdater
16 {
17 if ((self = [super init]))
18 updater = anUpdater;
19 return self;
20 }
21
43a0a7d @uliwitness Merge of changes from SVN repository:
uliwitness authored
22 - (NSString *)description { return [NSString stringWithFormat:@"%@ <%@, %@>", [self class], [host bundlePath], [host installationPath]]; }
c386b70 @andymatuschak Partial fix for 245277: basic descriptions for some Sparkle classes. …
andymatuschak authored
23
478e0a5 @andymatuschak Fixed a potential security vulnerability in which the download is tra…
andymatuschak authored
24 - (void)checkForUpdatesAtURL:(NSURL *)URL host:(SUHost *)h
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
25 {
478e0a5 @andymatuschak Fixed a potential security vulnerability in which the download is tra…
andymatuschak authored
26 appcastURL = [URL copy];
98832c4 @andymatuschak Beginnings of insane SUHost-based refactoring to get rid of NSBundle+…
andymatuschak authored
27 host = [h retain];
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
28 }
29
30 - (void)abortUpdate
31 {
32 [self setValue:[NSNumber numberWithBool:YES] forKey:@"finished"];
bc52c01 @andymatuschak Made SUUpdateDriver use notifications instead of KVO to let SUUpdater…
andymatuschak authored
33 [[NSNotificationCenter defaultCenter] postNotificationName:SUUpdateDriverFinishedNotification object:self];
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
34 }
35
36 - (BOOL)finished { return finished; }
46312a2 @andymatuschak Fixes 258060
andymatuschak authored
37
38 - (void)dealloc
39 {
40 [host release];
478e0a5 @andymatuschak Fixed a potential security vulnerability in which the download is tra…
andymatuschak authored
41 [appcastURL release];
46312a2 @andymatuschak Fixes 258060
andymatuschak authored
42 [super dealloc];
43 }
44
4ba453f @rudyrichter support for encrypted disk images
rudyrichter authored
45 - (SUHost*)host
46 {
47 return host;
48 }
49
50 - (void)setHost:(SUHost*)newHost
51 {
52 [host release];
53 host = [newHost retain];
54 }
55
bc3be9a Touched practically every line of code in a super-monster-awesome ref…
andym authored
56 @end
Something went wrong with that request. Please try again.