From c386b704b5a78a8149f33d0a474e88caa76fbb4b Mon Sep 17 00:00:00 2001 From: Andy Matuschak Date: Tue, 19 Aug 2008 21:24:26 -0700 Subject: [PATCH] Partial fix for 245277: basic descriptions for some Sparkle classes. Thanks to Christiaan Hofman for the patch. --- SUAutomaticUpdateAlert.m | 1 + SUHost.m | 2 ++ SUStatusController.m | 2 ++ SUUnarchiver.m | 2 ++ SUUpdateAlert.m | 2 ++ SUUpdateDriver.m | 2 ++ SUUpdatePermissionPrompt.m | 2 ++ SUUpdater.m | 2 ++ 8 files changed, 15 insertions(+) diff --git a/SUAutomaticUpdateAlert.m b/SUAutomaticUpdateAlert.m index 3c800232..b4e3fc8c 100644 --- a/SUAutomaticUpdateAlert.m +++ b/SUAutomaticUpdateAlert.m @@ -33,6 +33,7 @@ [super dealloc]; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } - (IBAction)installNow:sender { diff --git a/SUHost.m b/SUHost.m index f6e857e3..85d92d38 100644 --- a/SUHost.m +++ b/SUHost.m @@ -28,6 +28,8 @@ [super dealloc]; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [self bundlePath]]; } + - (NSBundle *)bundle { return bundle; diff --git a/SUStatusController.m b/SUStatusController.m index aa788810..1a810867 100644 --- a/SUStatusController.m +++ b/SUStatusController.m @@ -31,6 +31,8 @@ [super dealloc]; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } + - (void)awakeFromNib { [[self window] center]; diff --git a/SUUnarchiver.m b/SUUnarchiver.m index 9d1ee354..03cfaac0 100644 --- a/SUUnarchiver.m +++ b/SUUnarchiver.m @@ -27,6 +27,8 @@ extern NSMutableArray *__unarchiverImplementations; return nil; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], archivePath]; } + - (void)setDelegate:del { delegate = del; diff --git a/SUUpdateAlert.m b/SUUpdateAlert.m index 865a5424..94af5634 100644 --- a/SUUpdateAlert.m +++ b/SUUpdateAlert.m @@ -25,6 +25,8 @@ return self; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } + - (void)dealloc { [updateItem release]; diff --git a/SUUpdateDriver.m b/SUUpdateDriver.m index f5b75295..368fd7f0 100644 --- a/SUUpdateDriver.m +++ b/SUUpdateDriver.m @@ -18,6 +18,8 @@ NSString *SUUpdateDriverFinishedNotification = @"SUUpdateDriverFinished"; return self; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } + - (void)checkForUpdatesAtURL:(NSURL *)appcastURL host:(SUHost *)h { host = [h retain]; diff --git a/SUUpdatePermissionPrompt.m b/SUUpdatePermissionPrompt.m index 8d0b80b5..00cfd7e4 100644 --- a/SUUpdatePermissionPrompt.m +++ b/SUUpdatePermissionPrompt.m @@ -43,6 +43,8 @@ [NSApp runModalForWindow:[prompt window]]; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } + - (void)awakeFromNib { if (![self shouldAskAboutProfile]) diff --git a/SUUpdater.m b/SUUpdater.m index 45b12ca8..7084f8c7 100644 --- a/SUUpdater.m +++ b/SUUpdater.m @@ -78,6 +78,8 @@ static NSString *SUUpdaterDefaultsObservationContext = @"SUUpdaterDefaultsObserv return [self initForBundle:[NSBundle mainBundle]]; } +- (NSString *)description { return [NSString stringWithFormat:@"%@ <%@>", [self class], [host bundlePath]]; } + - (void)applicationDidFinishLaunching:(NSNotification *)note { BOOL shouldPrompt = NO;