~andymatuschak/sparkle/main

« back to all changes in this revision

Viewing changes to SUUpdater.m

  • Committer: Andy Matuschak
  • Date: 2008-07-24 06:40:01 UTC
  • mto: This revision was merged to the branch mainline in revision 256.
  • Revision ID: andy@andymatuschak.org-20080724064001-yf8xa2h887s7bui0
Fixes 243884
Made Sparkle.h no longer a massive multi-headed abomination: now only SUAppcastItem, SUAppcast and SUUpdater (and SUVersionComparisonProtocol because it's part of the delegate protocol) are public.

COMPATIBILITY ISSUE:
This means there's no longer a public SUProbingUpdateDriver or a checkForUpdatesWithDriver: method. Now use checkForUpdateInformation. I may change that API before release, though. I'm thinking it might be better to give the delegate the opportunity to reject a potential update instead: then you'd just call checkForUpdatesInBackground and override that delegate method to always return NO. We'll see.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
//  Copyright 2006 Andy Matuschak. All rights reserved.
7
7
//
8
8
 
9
 
#import "Sparkle.h"
10
9
#import "SUUpdater.h"
11
10
 
 
11
#import "SUHost.h"
 
12
#import "SUUpdatePermissionPrompt.h"
 
13
 
 
14
#import "SUAutomaticUpdateDriver.h"
 
15
#import "SUProbingUpdateDriver.h"
 
16
#import "SUUserInitiatedUpdateDriver.h"
 
17
#import "SUScheduledUpdateDriver.h"
 
18
 
12
19
@interface SUUpdater (Private)
 
20
- (void)checkForUpdatesWithDriver:(SUUpdateDriver *)updateDriver;
13
21
- (NSArray *)feedParameters;
14
22
- (BOOL)automaticallyUpdates;
15
23
- (BOOL)shouldScheduleUpdateCheck;
162
170
        [self checkForUpdatesWithDriver:[[[SUUserInitiatedUpdateDriver alloc] init] autorelease]];
163
171
}
164
172
 
 
173
- (void)checkForUpdateInformation
 
174
{
 
175
        [self checkForUpdatesWithDriver:[[[SUProbingUpdateDriver alloc] init] autorelease]];
 
176
}
 
177
 
165
178
- (void)checkForUpdatesWithDriver:(SUUpdateDriver *)d
166
179
{
167
180
        if ([self updateInProgress]) { return; }