aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPGrowlController.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/SPGrowlController.m')
-rw-r--r--Source/SPGrowlController.m18
1 files changed, 14 insertions, 4 deletions
diff --git a/Source/SPGrowlController.m b/Source/SPGrowlController.m
index 7c352b9f..481bfdd1 100644
--- a/Source/SPGrowlController.m
+++ b/Source/SPGrowlController.m
@@ -33,6 +33,12 @@ static SPGrowlController *sharedGrowlController = nil;
@class SPWindowController;
+@interface SPGrowlController ()
+
+- (double)milliTime;
+
+@end
+
@implementation SPGrowlController
/**
@@ -72,6 +78,8 @@ static SPGrowlController *sharedGrowlController = nil;
return self;
}
+#pragma mark -
+
/**
* Posts a Growl notification using the supplied details and default values.
* Calls the notification after a tiny delay to allow isKeyWindow to have updated
@@ -121,8 +129,8 @@ static SPGrowlController *sharedGrowlController = nil;
// Don't post the notification if the notification document is frontmost
// as that suggests the user is already viewing the notification result.
- if ([[document parentWindow] isKeyWindow]
- && [[[document parentTabViewItem] tabView] selectedTabViewItem] == [document parentTabViewItem])
+ if ([[document parentWindow] isKeyWindow] &&
+ [[[document parentTabViewItem] tabView] selectedTabViewItem] == [document parentTabViewItem])
{
postNotification = NO;
}
@@ -159,9 +167,11 @@ static SPGrowlController *sharedGrowlController = nil;
NSUInteger documentHash = [[clickContext objectForKey:@"notificationDocumentHash"] unsignedIntegerValue];
// Loop through the windows, looking for the document
- for (NSWindow *eachWindow in [NSApp orderedWindows]) {
+ for (NSWindow *eachWindow in [NSApp orderedWindows])
+ {
if ([[eachWindow windowController] isKindOfClass:[SPWindowController class]]) {
- for (SPDatabaseDocument *eachDocument in [[eachWindow windowController] documents]) {
+ for (SPDatabaseDocument *eachDocument in [[eachWindow windowController] documents])
+ {
if ([eachDocument hash] == documentHash) {
[NSApp activateIgnoringOtherApps:YES];
[eachDocument makeKeyDocument];