Commits

Anonymous committed e108a4a

Fixed some of the images stuff...

Comments (0)

Files changed (4)

Binary file modified.
 	NSNumber *defaultValue = [NSNumber numberWithBool:[_newNotificationDefault state] == NSOnState];
 	NSDictionary *aNuDict = [NSDictionary dictionaryWithObjectsAndKeys:			[_newNotificationTitle stringValue], GROWL_NOTIFICATION_TITLE,
 																				[_newNotificationDescription stringValue], GROWL_NOTIFICATION_DESCRIPTION,
-																				/* [_newNotificationImage image], GROWL_NOTIFICATION_ICON ,*/
+																				[[_newNotificationImage image] TIFFRepresentation], GROWL_NOTIFICATION_ICON ,
 																				defaultValue, GROWL_NOTIFICATION_DEFAULT,
 																				nil];
 	[_notifications addObject:aNuDict];

Growl.xcode/project.pbxproj

 				CB5F838A0638B78200EADD7A,
 				CB1C5D1B063E432F007052EE,
 				CB1C5D1C063E432F007052EE,
+				F57BFE2C0669037C00DE5BFD,
+				F57BFE2D0669037C00DE5BFD,
 			);
 			isa = PBXGroup;
 			name = Classes;
 				CB5F838B0638B78200EADD7A,
 				CBF0743A0659B1F4000B4B77,
 				CBF073CB0659A94F000B4B77,
+				F57BFE2E0669037C00DE5BFD,
 			);
 			isa = PBXHeadersBuildPhase;
 			runOnlyForDeploymentPostprocessing = 0;
 				CB5F838C0638B78200EADD7A,
 				CBF0743F0659B202000B4B77,
 				CB5F83A80638B8C800EADD7A,
+				F57BFE2F0669037C00DE5BFD,
 			);
 			isa = PBXSourcesBuildPhase;
 			runOnlyForDeploymentPostprocessing = 0;
 			refType = 4;
 			sourceTree = "<group>";
 		};
+		F57BFE2C0669037C00DE5BFD = {
+			fileEncoding = 30;
+			isa = PBXFileReference;
+			lastKnownFileType = sourcecode.c.h;
+			path = NSGrowlAdditions.h;
+			refType = 4;
+			sourceTree = "<group>";
+		};
+		F57BFE2D0669037C00DE5BFD = {
+			fileEncoding = 30;
+			isa = PBXFileReference;
+			lastKnownFileType = sourcecode.c.objc;
+			path = NSGrowlAdditions.m;
+			refType = 4;
+			sourceTree = "<group>";
+		};
+		F57BFE2E0669037C00DE5BFD = {
+			fileRef = F57BFE2C0669037C00DE5BFD;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
+		F57BFE2F0669037C00DE5BFD = {
+			fileRef = F57BFE2D0669037C00DE5BFD;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
 	};
 	rootObject = 089C1669FE841209C02AAC07;
 }

GrowlController.m

 #pragma mark -
 
 - (void) dispatchNotification:(NSNotification *) note {
+    NSImage *image;
+    
 	NSLog( @"%@", note );
 	
 	NSMutableDictionary *aDict = [NSMutableDictionary dictionaryWithDictionary:[note userInfo]];
-	[aDict objectForKey:GROWL_NOTIFICATION_ICON] ? [[_tickets objectForKey:[aDict objectForKey:GROWL_APP_NAME]] icon]
-												 : [aDict objectForKey:GROWL_NOTIFICATION_ICON];
+        if([aDict objectForKey:GROWL_NOTIFICATION_ICON]){
+            image = [[NSImage alloc] initWithData:[aDict objectForKey:GROWL_NOTIFICATION_ICON]];
+            [aDict removeObjectForKey:GROWL_NOTIFICATION_ICON];
+            [image autorelease];
+        }else{
+            image = [[_tickets objectForKey:[aDict objectForKey:GROWL_APP_NAME]] icon];
+        }
+        
+        if(image != nil){
+            [aDict setObject:image forKey:GROWL_NOTIFICATION_ICON];
+        }
 	NSLog( @"%@", [aDict objectForKey:GROWL_NOTIFICATION_ICON] );
 	[_displayController displayNotificationWithInfo:aDict];
 }