Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Moving over code from other repo

Sorry, no commit history
  • Loading branch information...
commit 46af0fc5bdc2db9bd477aa33f2f2c43f553a59ba 1 parent ec28e56
@stigi authored
Showing with 1,060 additions and 13,025 deletions.
  1. +25 −32 {source/Growl → }/GrowlDefines.h
  2. +61 −143 {source/Growl → }/GrowlDefinesInternal.h
  3. +6 −14 {source/Growl → }/GrowlDisplayPlugin.h
  4. +20 −35 {source/Growl → }/GrowlDisplayWindowController.h
  5. +79 −0 GrowlNotification.h
  6. +9 −9 {source/Growl → }/GrowlNotificationDisplayBridge.h
  7. +15 −17 {source/Growl → }/GrowlPlugin.h
  8. +55 −0 GrowlPluginPreferenceStrings.h
  9. +58 −121 MountainGrowl.xcodeproj/project.pbxproj
  10. +7 −0 MountainGrowl_Prefix.pch
  11. BIN  de.lproj/Localizable.strings
  12. +1 −1  resources/Info.plist
  13. +0 −2,748 resources/de.lproj/GrowlSamplePrefs.xib
  14. BIN  resources/de.lproj/Localizable.strings
  15. +0 −2,777 resources/en.lproj/GrowlSamplePrefs.xib
  16. BIN  resources/en.lproj/InfoPlist.strings
  17. BIN  resources/en.lproj/Localizable.strings
  18. +0 −2,779 resources/fr.lproj/GrowlSamplePrefs.xib
  19. +0 −2,779 resources/ja.lproj/GrowlSamplePrefs.xib
  20. +0 −34 source/Growl/CFDictionaryAdditions.c
  21. +0 −19 source/Growl/CFDictionaryAdditions.h
  22. +0 −38 source/Growl/CFGrowlDefines.h
  23. +0 −71 source/Growl/GrowlAbstractSingletonObject.h
  24. +0 −72 source/Growl/GrowlApplicationNotification.h
  25. +0 −20 source/Growl/GrowlImageAdditions.h
  26. +0 −95 source/Growl/GrowlImageAdditions.m
  27. +0 −114 source/Growl/GrowlPositionController.h
  28. +0 −60 source/Growl/GrowlPositioningDefines.h
  29. +0 −34 source/Growl/NSWindow+Transforms.h
  30. +0 −14 source/Growl/Transitions/GrowlFadingWindowTransition.h
  31. +0 −22 source/Growl/Transitions/GrowlFlippingWindowTransition.h
  32. +0 −19 source/Growl/Transitions/GrowlScaleWindowTransition.h
  33. +0 −17 source/Growl/Transitions/GrowlShrinkingWindowTransition.h
  34. +0 −22 source/Growl/Transitions/GrowlSlidingWindowTransition.h
  35. +0 −90 source/Growl/Transitions/GrowlWindowTransition.h
  36. +0 −19 source/Growl/Transitions/GrowlWipeWindowTransition.h
  37. +0 −18 source/GrowlSampleDisplay.h
  38. +0 −60 source/GrowlSampleDisplay.m
  39. +0 −80 source/GrowlSamplePrefs.h
  40. +0 −227 source/GrowlSamplePrefs.m
  41. +0 −18 source/GrowlSampleWindowController.h
  42. +0 −122 source/GrowlSampleWindowController.m
  43. +0 −36 source/GrowlSampleWindowView.h
  44. +0 −249 source/GrowlSampleWindowView.m
  45. +22 −0 source/MountainGrowlDisplay.h
  46. +90 −0 source/MountainGrowlDisplay.m
  47. +18 −0 source/MountainGrowlPrefs.h
  48. +39 −0 source/MountainGrowlPrefs.m
  49. +555 −0 source/MountainGrowlPrefs.xib
View
57 source/Growl/GrowlDefines.h → GrowlDefines.h
@@ -7,10 +7,8 @@
#ifdef __OBJC__
#define XSTR(x) (@x)
-#define STRING_TYPE NSString *
#else
#define XSTR CFSTR
-#define STRING_TYPE CFStringRef
#endif
/*! @header GrowlDefines.h
@@ -56,7 +54,7 @@
* This key is optional.
*/
#define GROWL_APP_ID XSTR("ApplicationId")
-/*! @defined GROWL_APP_ICON
+/*! @defined GROWL_APP_ICON_DATA
* @abstract The image data for your application's icon.
* @discussion Image data representing your application's icon. This may be
* superimposed on a notification icon as a badge, used as the notification
@@ -66,7 +64,7 @@
*
* Optional. Not supported by all display plugins.
*/
-#define GROWL_APP_ICON XSTR("ApplicationIcon")
+#define GROWL_APP_ICON_DATA XSTR("ApplicationIcon")
/*! @defined GROWL_NOTIFICATIONS_DEFAULT
* @abstract The array of notifications to turn on by default.
* @discussion These are the names of the notifications that should be enabled
@@ -144,20 +142,20 @@
*/
#define GROWL_NOTIFICATION_DESCRIPTION XSTR("NotificationDescription")
/*! @defined GROWL_NOTIFICATION_ICON
- * @discussion Image data for the notification icon. Must be in a format
+ * @discussion Image data for the notification icon. Image data must be in a format
* supported by NSImage, such as TIFF, PNG, GIF, JPEG, BMP, PICT, or PDF.
*
* Optional. Not supported by all display plugins.
*/
-#define GROWL_NOTIFICATION_ICON XSTR("NotificationIcon")
+#define GROWL_NOTIFICATION_ICON_DATA XSTR("NotificationIcon")
/*! @defined GROWL_NOTIFICATION_APP_ICON
* @discussion Image data for the application icon, in case GROWL_APP_ICON does
- * not apply for some reason. Must be in a format supported by NSImage, such
+ * not apply for some reason. Image data be in a format supported by NSImage, such
* as TIFF, PNG, GIF, JPEG, BMP, PICT, or PDF.
*
* Optional. Not supported by all display plugins.
*/
-#define GROWL_NOTIFICATION_APP_ICON XSTR("NotificationAppIcon")
+#define GROWL_NOTIFICATION_APP_ICON_DATA XSTR("NotificationAppIcon")
/*! @defined GROWL_NOTIFICATION_PRIORITY
* @discussion The priority of the notification as an integer number from
* -2 to +2 (+2 being highest).
@@ -185,16 +183,6 @@
*/
#define GROWL_NOTIFICATION_CLICK_CONTEXT XSTR("NotificationClickContext")
-/*! @defined GROWL_DISPLAY_PLUGIN
- * @discussion The name of a display plugin which should be used for this notification.
- * Optional. If this key is not set or the specified display plugin does not
- * exist, the display plugin stored in the application ticket is used. This key
- * allows applications to use different default display plugins for their
- * notifications. The user can still override those settings in the preference
- * pane.
- */
-#define GROWL_DISPLAY_PLUGIN XSTR("NotificationDisplayPlugin")
-
/*! @defined GROWL_NOTIFICATION_IDENTIFIER
* @abstract An identifier for the notification for coalescing purposes.
* Notifications with the same identifier fall into the same class; only
@@ -245,7 +233,7 @@
* The userInfo dictionary for this notification can contain these keys:
* <ul>
* <li>GROWL_APP_NAME</li>
- * <li>GROWL_APP_ICON</li>
+ * <li>GROWL_APP_ICON_DATA</li>
* <li>GROWL_NOTIFICATIONS_ALL</li>
* <li>GROWL_NOTIFICATIONS_DEFAULT</li>
* </ul>
@@ -288,12 +276,6 @@
* Growl_PostNotification.
*/
#define GROWL_NOTIFICATION XSTR("GrowlNotification")
-/*! @defined GROWL_SHUTDOWN
-* @abstract The distributed notification name that tells Growl to shutdown.
-* @discussion The Growl preference pane posts this notification when the
-* "Stop Growl" button is clicked.
-*/
-#define GROWL_SHUTDOWN XSTR("GrowlShutdown")
/*! @defined GROWL_PING
* @abstract A distributed notification to check whether Growl is running.
* @discussion This is used by the Growl preference pane. If it receives a
@@ -313,15 +295,26 @@
* registration dictionary supplied by its delegate.
*/
#define GROWL_IS_READY XSTR("Lend Me Some Sugar; I Am Your Neighbor!")
-/*! @defined GROWL_NOTIFICATION_CLICKED
- * @abstract The distributed notification sent when a supported notification is clicked.
+
+
+/*! @defined GROWL_DISTRIBUTED_NOTIFICATION_CLICKED_SUFFIX
+ * @abstract Part of the name of the distributed notification sent when a supported notification is clicked.
* @discussion When a Growl notification with a click context is clicked on by
- * the user, Growl posts this distributed notification.
- * The GrowlApplicationBridge responds to this notification by calling a
- * callback in its delegate.
+ * the user, Growl posts a distributed notification whose name is in the format:
+ * [NSString stringWithFormat:@"%@-%d-%@", appName, pid, GROWL_DISTRIBUTED_NOTIFICATION_CLICKED_SUFFIX]
+ * The GrowlApplicationBridge responds to this notification by calling a callback in its delegate.
+ */
+#define GROWL_DISTRIBUTED_NOTIFICATION_CLICKED_SUFFIX XSTR("GrowlClicked!")
+
+/*! @defined GROWL_DISTRIBUTED_NOTIFICATION_TIMED_OUT_SUFFIX
+ * @abstract Part of the name of the distributed notification sent when a supported notification times out without being clicked.
+ * @discussion When a Growl notification with a click context times out, Growl posts a distributed notification
+ * whose name is in the format:
+ * [NSString stringWithFormat:@"%@-%d-%@", appName, pid, GROWL_DISTRIBUTED_NOTIFICATION_TIMED_OUT_SUFFIX]
+ * The GrowlApplicationBridge responds to this notification by calling a callback in its delegate.
+ * NOTE: The user may have actually clicked the 'close' button; this triggers an *immediate* time-out of the notification.
*/
-#define GROWL_NOTIFICATION_CLICKED XSTR("GrowlClicked!")
-#define GROWL_NOTIFICATION_TIMED_OUT XSTR("GrowlTimedOut!")
+#define GROWL_DISTRIBUTED_NOTIFICATION_TIMED_OUT_SUFFIX XSTR("GrowlTimedOut!")
/*! @group Other symbols */
/* Symbols which don't fit into any of the other categories. */
View
204 source/Growl/GrowlDefinesInternal.h → GrowlDefinesInternal.h
@@ -30,26 +30,6 @@
*/
/*!
- * @defined NSInteger
- * @abstract Typedef to int so Growl will compile on pre-10.5 SDKs.
- */
-#ifndef NSINTEGER_DEFINED
-typedef int NSInteger;
-typedef unsigned int NSUInteger;
-#define NSINTEGER_DEFINED
-#endif
-
-/*!
- * @defined CGFloat
- * @abstract Typedef to float so Growl will compile on pre-10.5 SDKs.
- */
-#ifndef CGFLOAT_DEFINED
-typedef float CGFloat;
-#define CGFLOAT_IS_DOUBLE 0
-#define CGFLOAT_DEFINED
-#endif
-
-/*!
* @defined GrowlCGFloatCeiling()
* @abstract Macro for the ceil() function that uses a different precision depending on the CPU architecture.
*/
@@ -71,15 +51,15 @@ typedef float CGFloat;
#define GrowlCGFloatFloor(x) floorf(x)
#endif
-/*! @defined GROWL_TCP_PORT
- * @abstract The TCP listen port for Growl notification servers.
+/*! @defined GROWL_TCP_DO_PORT
+ * @abstract The TCP listen port for Growl's DirectObject-based notification servers.
*/
-#define GROWL_TCP_PORT 23052
+#define GROWL_TCP_DO_PORT 23052
-/*! @defined GROWL_UDP_PORT
- * @abstract The UDP listen port for Growl notification servers.
+/*! @defined GROWL_TCP_PORT
+ * @abstract The TCP listen port for Growl's protocol-based notification servers.
*/
-#define GROWL_UDP_PORT 9887
+#define GROWL_TCP_PORT 23053
/*! @defined GROWL_PROTOCOL_VERSION
* @abstract The current version of the Growl network-notifications protocol (without encryption).
@@ -116,124 +96,27 @@ typedef float CGFloat;
*/
#define GROWL_TYPE_NOTIFICATION_NOAUTH 5
-#define ATTRIBUTE_PACKED __attribute((packed))
-
-/*! @struct GrowlNetworkPacket
- * @abstract This struct is a header common to all incoming Growl network
- * packets which identifies the type and version of the packet.
+/*! @defined GROWL_NOTIFICATION_CLICKED
+ * @abstract Posted to the default notification center when the user clicks a notification
*/
-struct GrowlNetworkPacket {
- unsigned char version;
- unsigned char type;
-} ATTRIBUTE_PACKED;
+#define GROWL_NOTIFICATION_CLICKED @"GrowlNotificationClicked(Internal)"
-/*!
- * @struct GrowlNetworkRegistration
- * @abstract The format of a registration packet.
- * @discussion A Growl client that wants to register with a Growl server sends
- * a packet in this format.
- * @field common The Growl packet header.
- * @field appNameLen The name of the application that is registering.
- * @field numAllNotifications The number of notifications in the list.
- * @field numDefaultNotifications The number of notifications in the list that are enabled by default.
- * @field data Variable-sized data.
- */
-struct GrowlNetworkRegistration {
- struct GrowlNetworkPacket common;
- /* This name is used both internally and in the Growl
- * preferences.
- *
- * The application name should remain stable between different versions
- * and incarnations of your application.
- * For example, "SurfWriter" is a good app name, whereas "SurfWriter 2.0"
- * and "SurfWriter Lite" are not.
- *
- * In addition to being unsigned, the application name length is in
- * network byte order.
- */
- unsigned short appNameLen;
- /* These names are used both internally and in the Growl
- * preferences. For this reason, they should be human-readable.
- */
- unsigned char numAllNotifications;
-
- unsigned char numDefaultNotifications;
- /* The variable-sized data of a registration is:
- * - The application name, in UTF-8 encoding, for appNameLen bytes.
- * - The list of all notification names.
- * - The list of default notifications, as 8-bit unsigned indices into the list of all notifications.
- * - The MD5/SHA256 checksum of all the data preceding the checksum.
- *
- * Each notification name is encoded as:
- * - Length: two bytes, unsigned, network byte order.
- * - Name: As many bytes of UTF-8-encoded text as the length says.
- * And there are numAllNotifications of these.
- */
- unsigned char data[];
-} ATTRIBUTE_PACKED;
+/*! @defined GROWL_NOTIFICATION_TIMED_OUT
+ * @abstract Posted to the default notification center when a notification times out (or is closed via the close button)
+ */
+#define GROWL_NOTIFICATION_TIMED_OUT @"GrowlNotificationTimedOut(Internal)"
-/*!
- * @struct GrowlNetworkNotification
- * @abstract The format of a notification packet.
- * @discussion A Growl client that wants to post a notification to a Growl
- * server sends a packet in this format.
- * @field common The Growl packet header.
- * @field flags The priority number and the sticky bit.
- * @field nameLen The length of the notification name.
- * @field titleLen The length of the notification title.
- * @field descriptionLen The length of the notification description.
- * @field appNameLen The length of the application name.
- * @field data Variable-sized data.
- */
-struct GrowlNetworkNotification {
- struct GrowlNetworkPacket common;
- /*!
- * @struct GrowlNetworkNotificationFlags
- * @abstract Various flags.
- * @discussion This 16-bit packed structure contains the priority as a
- * signed 3-bit integer from -2 to +2, and the sticky flag as a single bit.
- * The high 12 bits of the structure are reserved for future use.
- * @field reserved reserved for future use.
- * @field priority the priority as a signed 3-bit integer from -2 to +2.
- * @field sticky the sticky flag.
- */
- struct GrowlNetworkNotificationFlags {
-#ifdef __BIG_ENDIAN__
- unsigned reserved: 12;
- signed priority: 3;
- unsigned sticky: 1;
-#else
- unsigned sticky: 1;
- signed priority: 3;
- unsigned reserved: 12;
-#endif
- } ATTRIBUTE_PACKED flags; //size = 16 (12 + 3 + 1)
-
- /* In addition to being unsigned, the notification name length
- * is in network byte order.
- */
- unsigned short nameLen;
- /* @discussion In addition to being unsigned, the title length is in
- * network byte order.
- */
- unsigned short titleLen;
- /* In addition to being unsigned, the description length is in
- * network byte order.
- */
- unsigned short descriptionLen;
- /* In addition to being unsigned, the application name length
- * is in network byte order.
- */
- unsigned short appNameLen;
- /* The variable-sized data of a notification is:
- * - Notification name, in UTF-8 encoding, for nameLen bytes.
- * - Title, in UTF-8 encoding, for titleLen bytes.
- * - Description, in UTF-8 encoding, for descriptionLen bytes.
- * - Application name, in UTF-8 encoding, for appNameLen bytes.
- * - The MD5/SHA256 checksum of all the data preceding the checksum.
- */
- unsigned char data[];
-} ATTRIBUTE_PACKED;
+#define GROWL_NOTIFICATION_CLICK_CONTENT_TYPE @"NotificationCallbackClickContextType"
+#define GROWL_NOTIFICATION_CALLBACK_URL_TARGET @"NotificationCallbackURLTarget"
+#define GROWL_NOTIFICATION_CALLBACK_URL_TARGET_METHOD @"NotificationCallbackURLTargetMethod"
+#define GROWL_NOTIFICATION_INTERNAL_ID @"Growl Internal Notification ID"
+#define GROWL_NOTIFICATION_GNTP_RECEIVED @"GNTP Notification Received Headers"
+#define GROWL_NOTIFICATION_GNTP_SENT_BY @"GNTP Notification Sent-By"
+#define GROWL_GNTP_ORIGIN_MACHINE @"GNTP Origin-Machine-Name"
+#define GROWL_GNTP_ORIGIN_SOFTWARE_NAME @"GNTP Origin-Software-Name"
+#define GROWL_GNTP_ORIGIN_SOFTWARE_VERSION @"GNTP Origin-Software-Version"
+#define GROWL_GNTP_ORIGIN_PLATFORM_NAME @"GNTP Origin-Platform-Name"
+#define GROWL_GNTP_ORIGIN_PLATFORM_VERSION @"GNTP Origin-Platform-Versin"
/*! @defined GrowlEnabledKey
* @abstract Preference key controlling whether Growl is enabled.
@@ -255,6 +138,11 @@ struct GrowlNetworkNotification {
*/
#define GROWL_SCREENSHOT_MODE XSTR("ScreenshotMode")
+/*! @defined GROWL_CLICK_HANDLER_ENABLED
+ * @abstract An NSNumber boolean indicating whether click notifications should be sent to the originating application
+ */
+#define GROWL_CLICK_HANDLER_ENABLED XSTR("ClickHandlerEnabled")
+
/*! @defined GROWL_APP_LOCATION
* @abstract The location of this application.
* @discussion Contains either the POSIX path to the application, or a file-data dictionary (as used by the Dock).
@@ -262,12 +150,12 @@ struct GrowlNetworkNotification {
*/
#define GROWL_APP_LOCATION XSTR("AppLocation")
-/*! @defined GROWL_REMOTE_ADDRESS
+/*! @defined GROWL_UDP_REMOTE_ADDRESS
* @abstract The address of the host who sent this notification/registration.
* @discussion Contains an NSData with the address of the remote host who
* sent this notification/registration.
*/
-#define GROWL_REMOTE_ADDRESS XSTR("RemoteAddress")
+#define GROWL_UDP_REMOTE_ADDRESS XSTR("RemoteAddress")
/*!
* @defined GROWL_PREFPANE_BUNDLE_IDENTIFIER
@@ -471,6 +359,11 @@ struct GrowlNetworkNotification {
CFRelease(floatValue); } while(0)
#endif
+/*! @defined GROWL_CLOSE_NOTIFICATION
+ * @abstract Notification to close a Growl notification
+ * @discussion The object of this notification is the GROWL_NOTIFICATION_INTERNAL_ID of the notification
+ */
+#define GROWL_CLOSE_NOTIFICATION XSTR("GrowlCloseNotification")
/*! @defined GROWL_CLOSE_ALL_NOTIFICATIONS
* @abstract Notification to close all Growl notifications
@@ -487,4 +380,29 @@ struct GrowlNetworkNotification {
*/
#define FLOAT_EQ(x,y) (((y - FLT_EPSILON) < x) && (x < (y + FLT_EPSILON)))
+#if GROWLHELPERAPP
+extern NSString *const GrowlErrorDomain;
+
+enum {
+ GrowlPluginErrorMinimum = 1000,
+ GrowlPluginErrorMaximum = GrowlPluginErrorMinimum + 999,
+
+ GrowlDisplayErrorMinimum = GrowlPluginErrorMaximum + 1,
+ GrowlDisplayErrorMaximum = GrowlDisplayErrorMinimum + 999,
+
+ GrowlPathwayErrorMinimum = GrowlDisplayErrorMaximum + 1,
+ GrowlPathwayErrorMaximum = GrowlPathwayErrorMinimum + 999,
+};
+
+enum GrowlPathwayErrorCode {
+ //A pathway that can be toggled on or off could not be toggled on.
+ GrowlPathwayErrorCouldNotEnable = GrowlPathwayErrorMinimum,
+ //A pathway that can be toggled on or off could not be toggled off.
+ GrowlPathwayErrorCouldNotDisable,
+};
+
+#endif
+
+#define GrowlVisualDisplayWindowLevel NSStatusWindowLevel
+
#endif //ndef _GROWL_GROWLDEFINESINTERNAL_H
View
20 source/Growl/GrowlDisplayPlugin.h → GrowlDisplayPlugin.h
@@ -2,14 +2,14 @@
// GrowlDisplayPlugin.h
// Growl
//
-// Created by Mac-arena the Bored Zo on 2005-06-01.
+// Created by Peter Hosey on 2005-06-01.
// Copyright 2005-2006 The Growl Project. All rights reserved.
//
#import <Cocoa/Cocoa.h>
#import "GrowlPlugin.h"
-@class GrowlApplicationNotification, GrowlNotificationDisplayBridge;
+@class GrowlNotification, GrowlNotificationDisplayBridge;
@class GrowlDisplayWindowController;
//Info.plist keys for plug-in bundles.
@@ -38,19 +38,9 @@ extern NSString *GrowlDisplayPluginInfoKeyWindowNibName;
* @abstract Display a notification to the user.
* @param notification The notification to display.
* @discussion Unless you have a specific reason to override this method you should not do so.
- * All the magic should happen in <code>configureBridge:</code>
+ * All the magic should happen in the window controller's <code>setNotification:</code>
*/
-- (void) displayNotification:(GrowlApplicationNotification *)notification;
-
-/*! @method configureBridge:
- * @abstract Configures the chosen bridge before a notificaion is displayed.
- * @param bridge The bridge to configure.
- * @discussion This is the place where the magic happens. Override this method and do any
- * specific configuration here. This is the last port-of-call before a notification is displayed.
- * The default implementation does nothing so it is important that you override and provide an
- * implementation.
- */
-- (void) configureBridge:(GrowlNotificationDisplayBridge *)theBridge;
+- (void) displayNotification:(GrowlNotification *)notification;
/*! @method windowNibName
* @abstract Returns the name of the display's sole nib file (resulting in
@@ -72,4 +62,6 @@ extern NSString *GrowlDisplayPluginInfoKeyWindowNibName;
/* */
- (void) displayWindowControllerDidTakeDownWindow:(GrowlDisplayWindowController *)wc;
+- (BOOL) queuesNotifications;
+
@end
View
55 source/Growl/GrowlDisplayWindowController.h → GrowlDisplayWindowController.h
@@ -2,8 +2,8 @@
// GrowlDisplayWindowController.h
// Display Plugins
//
-// Created by Mac-arena the Bored Zo on 2005-06-03.
-// Copyright 2004-2006 The Growl Project. All rights reserved.
+// Created by Peter Hosey on 2005-06-03.
+// Copyright 2004-2011 The Growl Project, LLC. All rights reserved.
//
#import <Cocoa/Cocoa.h>
@@ -16,7 +16,7 @@
#define GrowlDisplayWindowControllerDidTakeWindowDownNotification @"GrowlDisplayWindowControllerDidTakeWindowDownNotification"
#define GrowlDisplayWindowControllerNotificationBlockedNotification @"GrowlDisplayWindowControllerNotificationBlockedNotification"
-@class GrowlWindowTransition, GrowlNotificationDisplayBridge, GrowlApplicationNotification, GrowlNotificationView;
+@class GrowlWindowTransition, GrowlNotificationDisplayBridge, GrowlNotification, GrowlNotificationView;
typedef enum {
GrowlDisplayUnknownStatus = 0,
@@ -25,13 +25,13 @@ typedef enum {
GrowlDisplayTransitioningOutStatus
} GrowlDisplayStatus;
-@interface GrowlDisplayWindowController : NSWindowController {
- GrowlApplicationNotification *notification; /* not sure if this will be needed since binding may work without */
+@interface GrowlDisplayWindowController : NSWindowController <NSWindowDelegate, NSAnimationDelegate> {
+ GrowlNotification *notification; /* not sure if this will be needed since binding may work without */
GrowlNotificationDisplayBridge *bridge;
SEL action;
id target;
- id clickContext;
+ BOOL didClick;
NSNumber *clickHandlerEnabled;
NSString *appName;
NSNumber *appPid;
@@ -39,7 +39,7 @@ typedef enum {
id delegate;
BOOL ignoresOtherNotifications;
-
+
CFTimeInterval transitionDuration;
NSMapTable *startTimes;
NSMapTable *endTimes;
@@ -48,11 +48,13 @@ typedef enum {
CFTimeInterval displayDuration;
NSUInteger screenNumber;
- NSUInteger screenshotMode: 1;
+ BOOL screenshotModeEnabled;
BOOL userRequestedClose;
unsigned WCReserved: 30;
+ NSInteger failureCount;
+ BOOL queuesNotes;
}
- (id) initWithWindowNibName:(NSString *)windowNibName bridge:(GrowlNotificationDisplayBridge *)displayBridge;
@@ -108,44 +110,23 @@ typedef enum {
#pragma mark -
/* Not to be called directly...these are managed via bindings */
-- (GrowlApplicationNotification *) notification;
-- (void) setNotification:(GrowlApplicationNotification *)theNotification;
+- (GrowlNotification *) notification;
+- (void) setNotification:(GrowlNotification *)theNotification;
/* Used to make an existing window controller update to a new or modified notification */
-- (void) updateToNotification:(GrowlApplicationNotification *)theNotification;
+- (void) updateToNotification:(GrowlNotification *)theNotification;
/* Not to be called directly...for KVO compliance only */
- (GrowlNotificationDisplayBridge *)bridge;
- (void) setBridge:(GrowlNotificationDisplayBridge *)theBridge;
/* Subclasses should call this *after* calling -[super initWithWindw:] to set the overall transition duration ... could offer a user pref as well */
-- (CFTimeInterval) transitionDuration;
-- (void) setTransitionDuration:(CFTimeInterval)theTransitionDuration;
-
-- (CFTimeInterval) displayDuration;
-- (void) setDisplayDuration:(CFTimeInterval)newDuration;
-
-- (BOOL) screenshotModeEnabled;
-- (void) setScreenshotModeEnabled:(BOOL) newScreenshotMode;
- (NSScreen *) screen;
- (void) setScreen:(NSScreen *)newScreen;
- (void) setScreenNumber:(NSUInteger)newScreenNumber;
-- (id) target;
-- (void) setTarget:(id)object;
-
-- (SEL) action;
-- (void) setAction:(SEL)selector;
-
-- (NSString *) notifyingApplicationName;
-- (void) setNotifyingApplicationName:(NSString *)inAppName;
-
-- (NSNumber *) notifyingApplicationProcessIdentifier;
-- (void) setNotifyingApplicationProcessIdentifier:(NSNumber *)inAppPid;
-
- (id) clickContext;
-- (void) setClickContext:(id) clickContext;
- (void) notificationClicked:(id) sender;
@@ -158,9 +139,13 @@ typedef enum {
- (NSNumber *) clickHandlerEnabled;
- (void) setClickHandlerEnabled:(NSNumber *)flag;
-- (BOOL) ignoresOtherNotifications;
-- (void) setIgnoresOtherNotifications:(BOOL)flag;
-
+@property (nonatomic, assign) BOOL ignoresOtherNotifications;
+@property (nonatomic, assign) SEL action;
+@property (nonatomic, retain) id target;
+@property (nonatomic, assign) BOOL screenshotModeEnabled;
+@property (nonatomic, assign) CFTimeInterval displayDuration;
+@property (nonatomic, assign) CFTimeInterval transitionDuration;
+@property (nonatomic, assign) NSInteger failureCount;
@end
/*!
View
79 GrowlNotification.h
@@ -0,0 +1,79 @@
+//
+// GrowlNotification.h
+// Growl
+//
+// Copyright 2005-2011 The Growl Project. All rights reserved.
+//
+
+@interface GrowlNotification: NSObject
+{
+ NSString *name;
+ NSString *applicationName;
+
+ NSString *title;
+ NSString *messageText;
+
+ NSImage *icon;
+
+ NSString *identifier;
+
+ BOOL sticky;
+ NSInteger priority;
+
+ NSDictionary *auxiliaryDictionary;
+
+ NSDictionary *cachedDictionaryRepresentation;
+}
+
++ (GrowlNotification *) notificationWithDictionary:(NSDictionary *)dict;
+- (GrowlNotification *) initWithDictionary:(NSDictionary *)dict;
+
+//You can pass nil for description.
+- (GrowlNotification *) initWithName:(NSString *)newName
+ applicationName:(NSString *)newAppName
+ title:(NSString *)newTitle
+ description:(NSString *)newDesc;
+
+#pragma mark -
+
+/*As of 1.3, this returns:
+ * * GROWL_NOTIFICATION_NAME
+ * * GROWL_APP_NAME
+ * * GROWL_NOTIFICATION_TITLE
+ * * GROWL_NOTIFICATION_DESCRIPTION
+ *You can pass this set to -dictionaryRepresentationWithKeys:.
+ */
++ (NSSet *) standardKeys;
+
+//Same as dictionaryRepresentationWithKeys:nil.
+- (NSDictionary *) dictionaryRepresentation;
+
+/*With nil, returns all of the standard keys plus the auxiliary dictionary.
+ *With non-nil, returns only the keys (from internal storage plus the auxiliary
+ * dictionary) that are in the set.
+ *In other words, returns the intersection of the standard dictionary keys, the
+ * auxiliary dictionary, and the provided keys.
+ */
+- (NSDictionary *) dictionaryRepresentationWithKeys:(NSSet *)keys;
+
+#pragma mark -
+
+@property(nonatomic, copy) NSString *name;
+@property(nonatomic, copy) NSString *applicationName;
+
+@property(nonatomic, copy) NSString *title;
+@property(nonatomic, copy) NSString *messageText;
+
+//Compatibility alias for messageText.
+- (NSString *) notificationDescription;
+
+@property(nonatomic, copy) NSImage *icon;
+
+@property(nonatomic, copy) NSString *identifier;
+
+@property(nonatomic, assign, getter=isSticky) BOOL sticky;
+@property(nonatomic, assign) NSInteger priority;
+
+@property(nonatomic, copy) NSDictionary *auxiliaryDictionary;
+
+@end
View
18 ...ce/Growl/GrowlNotificationDisplayBridge.h → GrowlNotificationDisplayBridge.h
@@ -2,13 +2,13 @@
// GrowlNotificationDisplayBridge.h
// Growl
//
-// Created by Mac-arena the Bored Zo on 2005-06-05.
+// Created by Peter Hosey on 2005-06-05.
// Copyright 2005-2006 The Growl Project. All rights reserved.
//
#import "GrowlDisplayPlugin.h"
-@class GrowlApplicationNotification, GrowlDisplayWindowController;
+@class GrowlNotification, GrowlDisplayWindowController;
/*! @class GrowlNotificationDisplayBridge
* @brief The File's Owner of a display nib.
@@ -22,7 +22,7 @@
@interface GrowlNotificationDisplayBridge : NSObject {
GrowlDisplayPlugin *display;
- GrowlApplicationNotification *notification;
+ GrowlNotification *notification;
NSString *windowNibName;
NSMutableArray *windowControllers;
Class windowControllerClass;
@@ -40,7 +40,7 @@
* @result An autoreleased display bridge.
*/
+ (GrowlNotificationDisplayBridge *) bridgeWithDisplay:(GrowlDisplayPlugin *)newDisplay
- notification:(GrowlApplicationNotification *)newNotification
+ notification:(GrowlNotification *)newNotification
windowControllerClass:(Class)wcc;
/*! @fn bridgeWithDisplay:notification:windowNibName:windowControllerClass:
@@ -55,7 +55,7 @@
* @result An autoreleased display bridge.
*/
+ (GrowlNotificationDisplayBridge *) bridgeWithDisplay:(GrowlDisplayPlugin *)newDisplay
- notification:(GrowlApplicationNotification *)newNotification
+ notification:(GrowlNotification *)newNotification
windowNibName:(NSString *)newWindowNibName
windowControllerClass:(Class)wcc;
@@ -71,7 +71,7 @@
* @result An display bridge.
*/
- (id) initWithDisplay:(GrowlDisplayPlugin *)newDisplay
- notification:(GrowlApplicationNotification *)newNotification
+ notification:(GrowlNotification *)newNotification
windowControllerClass:(Class)wcc;
/*! @fn initWithDisplay:notification:windowNibName:windowControllerClass:
@@ -86,7 +86,7 @@
* @result An display bridge.
*/
- (id) initWithDisplay:(GrowlDisplayPlugin *)newDisplay
- notification:(GrowlApplicationNotification *)newNotification
+ notification:(GrowlNotification *)newNotification
windowNibName:(NSString *)newWindowNibName
windowControllerClass:(Class)wcc;
@@ -124,7 +124,7 @@
*
* @return The notification being displayed.
*/
-- (GrowlApplicationNotification *) notification;
+- (GrowlNotification *) notification;
/*! @fn windowNibName
* @brief Returns the window nib name passed in by \c GrowlDisplayPlugin.
@@ -210,7 +210,7 @@
* @par
* The notification
*/
-- (void)setNotification:(GrowlApplicationNotification *)inNotification;
+- (void)setNotification:(GrowlNotification *)inNotification;
@end
@interface NSArray (GrowlDisplaySearching)
View
32 source/Growl/GrowlPlugin.h → GrowlPlugin.h
@@ -2,7 +2,7 @@
// GrowlPlugin.h
// Growl
//
-// Created by Mac-arena the Bored Zo on 2005-06-01.
+// Created by Peter Hosey on 2005-06-01.
// Copyright 2005-2006 The Growl Project. All rights reserved.
//
@@ -18,7 +18,7 @@
@interface GrowlPlugin : NSObject {
NSString *pluginName, *pluginAuthor, *pluginVersion, *pluginDesc;
NSBundle *pluginBundle;
- NSString *pluginPathname;
+ NSString *pluginPathName;
NSPreferencePane *preferencePane;
NSString *prefDomain;
@@ -42,49 +42,47 @@
*/
- (id) initWithBundle:(NSBundle *)bundle;
-
/*!
* @method name
* @abstract Returns the name of the receiver.
*/
-- (NSString *) name;
+@property (nonatomic, copy) NSString *name;
/*!
* @method author
* @abstract Returns the author of the receiver.
*/
-- (NSString *) author;
+@property (nonatomic, copy) NSString *author;
/*!
- * @method pluginDescription
- * @abstract Returns the description of the receiver.
+ * @method version
+ * @abstract Returns the version of the receiver.
*/
-- (NSString *) pluginDescription;
+@property (nonatomic, copy) NSString *version;
/*!
- * @method version
- * @abstract Returns the version of the receiver.
+ * @method pluginDescription
+ * @abstract Returns the plugin's description.
*/
-- (NSString *) version;
+@property (nonatomic, copy) NSString *pluginDescription;
/*!
* @method bundle
* @abstract Returns the bundle of the receiver.
*/
-- (NSBundle *) bundle;
+@property (nonatomic, retain) NSBundle *bundle;
/*!
* @method pathname
* @abstract Returns the pathname of the receiver.
*/
-- (NSString *) pathname;
+@property (nonatomic, copy) NSString *pathname;
/*!
-* @method pathname
+ * @method pathname
* @abstract Returns the string used to access the preference domain of the receiver.
*/
-- (NSString *) prefDomain;
-
+@property (nonatomic, retain) NSString *prefDomain;
/*! @method preferencePane
* @abstract Return an <code>NSPreferencePane</code> instance that manages
@@ -100,6 +98,6 @@
* The default implementation of this method returns <code>nil</code>.
* @result The preference pane. Can be <code>nil</code>.
*/
-- (NSPreferencePane *) preferencePane;
+@property (nonatomic, assign) NSPreferencePane *preferencePane;
@end
View
55 GrowlPluginPreferenceStrings.h
@@ -0,0 +1,55 @@
+//
+// GrowlPluginPreferenceStrings.h
+// Growl
+//
+// Created by Daniel Siemer on 1/30/12.
+// Copyright (c) 2012 The Growl Project. All rights reserved.
+//
+
+/* FOR GROWL DEVELOPED COCOA PLUGINS ONLY AT THIS TIME, NOT STABLE */
+
+#import <Foundation/Foundation.h>
+
+#define GrowlDisplayOpacity NSLocalizedStringFromTable(@"Opacity:", @"PluginPrefStrings", @"How clear the display is")
+#define GrowlDisplayDuration NSLocalizedStringFromTable(@"Duration:", @"PluginPrefStrings", @"How long a notification will stay on screen")
+
+#define GrowlDisplayPriority NSLocalizedStringFromTable(@"Priority: (low to high)", @"PluginPrefStrings", @"Label for columns of color wells for various priority levels")
+#define GrowlDisplayTextColor NSLocalizedStringFromTable(@"Text", @"PluginPrefStrings", @"Label for row of color wells for the text element of the plugin")
+#define GrowlDisplayBackgroundColor NSLocalizedStringFromTable(@"Background", @"PluginPrefStrings", @"Label for row of color wells for the background of the plugin")
+
+#define GrowlDisplayLimitLines NSLocalizedStringFromTable(@"Limit to 2-5 lines", @"PluginPrefStrings", @"Checkbox to limit the display to 2-5 lines")
+#define GrowlDisplayScreen NSLocalizedStringFromTable(@"Screen:", @"PluginPrefStrings", @"Label for box to select screen for display to use")
+#define GrowlDisplaySize NSLocalizedStringFromTable(@"Size:", @"PluginPrefStrings", @"Label for pop up box for selecting the size of the display")
+#define GrowlDisplaySizeNormal NSLocalizedStringFromTable(@"Normal", @"PluginPrefStrings", @"Normal size for the display")
+#define GrowlDisplaySizeLarge NSLocalizedStringFromTable(@"Large", @"PluginPrefStrings", @"Large size for the display")
+#define GrowlDisplaySizeSmall NSLocalizedStringFromTable(@"Small", @"PluginPrefStrings", @"Small size for the display")
+
+#define GrowlDisplayFloatingIcon NSLocalizedStringFromTable(@"Floating icon", @"PluginPrefStrings", @"Label for the floating icon checkbox")
+
+#define GrowlDisplayEffect NSLocalizedString(@"Effect:", @"Label for the effect to use")
+#define GrowlDisplayEffectSlide NSLocalizedString(@"Slide", @"A slide effect")
+#define GrowlDisplayEffectFade NSLocalizedString(@"Fade", @"A fade effect")
+
+@interface GrowlPluginPreferenceStrings : NSObject
+
+@property (nonatomic, retain) NSString *growlDisplayOpacity;
+@property (nonatomic, retain) NSString *growlDisplayDuration;
+
+@property (nonatomic, retain) NSString *growlDisplayPriority;
+@property (nonatomic, retain) NSString *growlDisplayTextColor;
+@property (nonatomic, retain) NSString *growlDisplayBackgroundColor;
+
+@property (nonatomic, retain) NSString *growlDisplayLimitLines;
+@property (nonatomic, retain) NSString *growlDisplayScreen;
+@property (nonatomic, retain) NSString *growlDisplaySize;
+@property (nonatomic, retain) NSString *growlDisplaySizeNormal;
+@property (nonatomic, retain) NSString *growlDisplaySizeLarge;
+@property (nonatomic, retain) NSString *growlDisplaySizeSmall;
+
+@property (nonatomic, retain) NSString *growlDisplayFloatingIcon;
+
+@property (nonatomic, retain) NSString *effectLabel;
+@property (nonatomic, retain) NSString *slideEffect;
+@property (nonatomic, retain) NSString *fadeEffect;
+
+@end
View
179 MountainGrowl.xcodeproj/project.pbxproj
@@ -3,66 +3,41 @@
archiveVersion = 1;
classes = {
};
- objectVersion = 45;
+ objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
8D5B49B4048680CD000E48DA /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7ADFEA557BF11CA2CBB /* Cocoa.framework */; };
- 932406361077A429008EEF09 /* GrowlSamplePrefs.xib in Resources */ = {isa = PBXBuildFile; fileRef = 9324062E1077A429008EEF09 /* GrowlSamplePrefs.xib */; };
- 932406371077A429008EEF09 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 932406311077A429008EEF09 /* InfoPlist.strings */; };
- 932408901077AF4F008EEF09 /* CFDictionaryAdditions.c in Sources */ = {isa = PBXBuildFile; fileRef = 9324088E1077AF4F008EEF09 /* CFDictionaryAdditions.c */; };
- 932408A41077AF86008EEF09 /* GrowlImageAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 932408A31077AF86008EEF09 /* GrowlImageAdditions.m */; };
- 93596AD60A84222E001C6860 /* GrowlSampleDisplay.m in Sources */ = {isa = PBXBuildFile; fileRef = 93596ACD0A84222E001C6860 /* GrowlSampleDisplay.m */; };
- 93596AD70A84222E001C6860 /* GrowlSamplePrefs.m in Sources */ = {isa = PBXBuildFile; fileRef = 93596ACF0A84222E001C6860 /* GrowlSamplePrefs.m */; };
- 93596AD80A84222E001C6860 /* GrowlSampleWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93596AD10A84222E001C6860 /* GrowlSampleWindowController.m */; };
- 93596AD90A84222E001C6860 /* GrowlSampleWindowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 93596AD30A84222E001C6860 /* GrowlSampleWindowView.m */; };
93596C160A842461001C6860 /* PreferencePanes.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 93596C150A842461001C6860 /* PreferencePanes.framework */; };
+ 946896D515D3D286006577C2 /* MountainGrowlDisplay.m in Sources */ = {isa = PBXBuildFile; fileRef = 946896D115D3D286006577C2 /* MountainGrowlDisplay.m */; };
+ 946896D615D3D286006577C2 /* MountainGrowlPrefs.m in Sources */ = {isa = PBXBuildFile; fileRef = 946896D315D3D286006577C2 /* MountainGrowlPrefs.m */; };
+ 946896D715D3D286006577C2 /* MountainGrowlPrefs.xib in Resources */ = {isa = PBXBuildFile; fileRef = 946896D415D3D286006577C2 /* MountainGrowlPrefs.xib */; };
+ 94D52B7115D3D313002D6080 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 94D52B6F15D3D313002D6080 /* Localizable.strings */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
089C1672FE841209C02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = "<absolute>"; };
089C167FFE841241C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = "<absolute>"; };
1058C7ADFEA557BF11CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = "<absolute>"; };
- 32DBCF630370AF2F00C91783 /* Sample_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Sample_Prefix.pch; sourceTree = "<group>"; };
+ 32DBCF630370AF2F00C91783 /* MountainGrowl_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MountainGrowl_Prefix.pch; sourceTree = "<group>"; };
8D5B49B6048680CD000E48DA /* MountainGrowl.growlView */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MountainGrowl.growlView; sourceTree = BUILT_PRODUCTS_DIR; };
- 9324062F1077A429008EEF09 /* de */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = de; path = resources/de.lproj/GrowlSamplePrefs.xib; sourceTree = "<group>"; };
- 932406301077A429008EEF09 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = resources/en.lproj/GrowlSamplePrefs.xib; sourceTree = "<group>"; };
- 932406321077A429008EEF09 /* en */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = en; path = resources/en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
- 932406331077A429008EEF09 /* fr */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = fr; path = resources/fr.lproj/GrowlSamplePrefs.xib; sourceTree = "<group>"; };
932406341077A429008EEF09 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = resources/Info.plist; sourceTree = "<group>"; };
- 932406351077A429008EEF09 /* ja */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = ja; path = resources/ja.lproj/GrowlSamplePrefs.xib; sourceTree = "<group>"; };
- 932407F21077AABC008EEF09 /* GrowlDisplayPlugin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlDisplayPlugin.h; path = source/Growl/GrowlDisplayPlugin.h; sourceTree = "<group>"; };
- 932407F51077AACC008EEF09 /* GrowlPlugin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlPlugin.h; path = source/Growl/GrowlPlugin.h; sourceTree = "<group>"; };
- 932407FB1077AAF9008EEF09 /* GrowlDisplayWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlDisplayWindowController.h; path = source/Growl/GrowlDisplayWindowController.h; sourceTree = "<group>"; };
- 932407FE1077AB18008EEF09 /* GrowlPositionController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlPositionController.h; path = source/Growl/GrowlPositionController.h; sourceTree = "<group>"; };
- 932407FF1077AB28008EEF09 /* GrowlDefines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlDefines.h; path = source/Growl/GrowlDefines.h; sourceTree = "<group>"; };
- 932408001077AB28008EEF09 /* GrowlDefinesInternal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlDefinesInternal.h; path = source/Growl/GrowlDefinesInternal.h; sourceTree = "<group>"; };
- 932408031077AB5F008EEF09 /* GrowlAbstractSingletonObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlAbstractSingletonObject.h; path = source/Growl/GrowlAbstractSingletonObject.h; sourceTree = "<group>"; };
- 932408341077ABA2008EEF09 /* GrowlPositioningDefines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlPositioningDefines.h; path = source/Growl/GrowlPositioningDefines.h; sourceTree = "<group>"; };
- 932408371077ABB5008EEF09 /* NSWindow+Transforms.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSWindow+Transforms.h"; path = "source/Growl/NSWindow+Transforms.h"; sourceTree = "<group>"; };
- 9324084E1077AC69008EEF09 /* GrowlApplicationNotification.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlApplicationNotification.h; path = source/Growl/GrowlApplicationNotification.h; sourceTree = "<group>"; };
- 932408771077AD8F008EEF09 /* GrowlFadingWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlFadingWindowTransition.h; sourceTree = "<group>"; };
- 932408781077AD8F008EEF09 /* GrowlFlippingWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlFlippingWindowTransition.h; sourceTree = "<group>"; };
- 932408791077AD8F008EEF09 /* GrowlScaleWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlScaleWindowTransition.h; sourceTree = "<group>"; };
- 9324087A1077AD8F008EEF09 /* GrowlShrinkingWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlShrinkingWindowTransition.h; sourceTree = "<group>"; };
- 9324087B1077AD8F008EEF09 /* GrowlSlidingWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlSlidingWindowTransition.h; sourceTree = "<group>"; };
- 9324087C1077AD8F008EEF09 /* GrowlWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlWindowTransition.h; sourceTree = "<group>"; };
- 9324087D1077AD8F008EEF09 /* GrowlWipeWindowTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlWipeWindowTransition.h; sourceTree = "<group>"; };
- 9324088E1077AF4F008EEF09 /* CFDictionaryAdditions.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = CFDictionaryAdditions.c; path = source/Growl/CFDictionaryAdditions.c; sourceTree = "<group>"; };
- 9324088F1077AF4F008EEF09 /* CFDictionaryAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CFDictionaryAdditions.h; path = source/Growl/CFDictionaryAdditions.h; sourceTree = "<group>"; };
- 932408931077AF63008EEF09 /* CFGrowlDefines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CFGrowlDefines.h; path = source/Growl/CFGrowlDefines.h; sourceTree = "<group>"; };
- 932408A21077AF86008EEF09 /* GrowlImageAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlImageAdditions.h; path = source/Growl/GrowlImageAdditions.h; sourceTree = "<group>"; };
- 932408A31077AF86008EEF09 /* GrowlImageAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GrowlImageAdditions.m; path = source/Growl/GrowlImageAdditions.m; sourceTree = "<group>"; };
- 932408AE1077AFB0008EEF09 /* GrowlNotificationDisplayBridge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GrowlNotificationDisplayBridge.h; path = source/Growl/GrowlNotificationDisplayBridge.h; sourceTree = "<group>"; };
- 93596ACC0A84222E001C6860 /* GrowlSampleDisplay.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GrowlSampleDisplay.h; sourceTree = "<group>"; };
- 93596ACD0A84222E001C6860 /* GrowlSampleDisplay.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GrowlSampleDisplay.m; sourceTree = "<group>"; };
- 93596ACE0A84222E001C6860 /* GrowlSamplePrefs.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GrowlSamplePrefs.h; sourceTree = "<group>"; };
- 93596ACF0A84222E001C6860 /* GrowlSamplePrefs.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GrowlSamplePrefs.m; sourceTree = "<group>"; };
- 93596AD00A84222E001C6860 /* GrowlSampleWindowController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GrowlSampleWindowController.h; sourceTree = "<group>"; };
- 93596AD10A84222E001C6860 /* GrowlSampleWindowController.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GrowlSampleWindowController.m; sourceTree = "<group>"; };
- 93596AD20A84222E001C6860 /* GrowlSampleWindowView.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = GrowlSampleWindowView.h; sourceTree = "<group>"; };
- 93596AD30A84222E001C6860 /* GrowlSampleWindowView.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = GrowlSampleWindowView.m; sourceTree = "<group>"; };
93596C150A842461001C6860 /* PreferencePanes.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = PreferencePanes.framework; path = /System/Library/Frameworks/PreferencePanes.framework; sourceTree = "<absolute>"; };
+ 946896D015D3D286006577C2 /* MountainGrowlDisplay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MountainGrowlDisplay.h; sourceTree = "<group>"; };
+ 946896D115D3D286006577C2 /* MountainGrowlDisplay.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MountainGrowlDisplay.m; sourceTree = "<group>"; };
+ 946896D215D3D286006577C2 /* MountainGrowlPrefs.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MountainGrowlPrefs.h; sourceTree = "<group>"; };
+ 946896D315D3D286006577C2 /* MountainGrowlPrefs.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MountainGrowlPrefs.m; sourceTree = "<group>"; };
+ 946896D415D3D286006577C2 /* MountainGrowlPrefs.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MountainGrowlPrefs.xib; sourceTree = "<group>"; };
+ 94D52B7015D3D313002D6080 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = resources/en.lproj/Localizable.strings; sourceTree = "<group>"; };
+ 94D52B7215D3D31E002D6080 /* de */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = de; path = de.lproj/Localizable.strings; sourceTree = "<group>"; };
+ 94D52BC715D3D5CA002D6080 /* GrowlPluginPreferenceStrings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlPluginPreferenceStrings.h; sourceTree = "<group>"; };
+ 94D52BC815D3D5CA002D6080 /* GrowlDisplayPlugin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlDisplayPlugin.h; sourceTree = "<group>"; };
+ 94D52BC915D3D5CA002D6080 /* GrowlDisplayWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlDisplayWindowController.h; sourceTree = "<group>"; };
+ 94D52BCA15D3D5CA002D6080 /* GrowlNotificationDisplayBridge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlNotificationDisplayBridge.h; sourceTree = "<group>"; };
+ 94D52BCC15D3D5E3002D6080 /* GrowlPlugin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GrowlPlugin.h; sourceTree = "<group>"; };
+ 94D52BCD15D3D678002D6080 /* GrowlNotification.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GrowlNotification.h; sourceTree = "<group>"; };
+ 94D52BCE15D3D6EE002D6080 /* GrowlDefines.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GrowlDefines.h; sourceTree = "<group>"; };
+ 94D52BCF15D3D72C002D6080 /* GrowlDefinesInternal.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GrowlDefinesInternal.h; sourceTree = "<group>"; };
D2F7E65807B2D6F200F64583 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = /System/Library/Frameworks/CoreData.framework; sourceTree = "<absolute>"; };
/* End PBXFileReference section */
@@ -104,8 +79,7 @@
089C167CFE841241C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
- 9324062E1077A429008EEF09 /* GrowlSamplePrefs.xib */,
- 932406311077A429008EEF09 /* InfoPlist.strings */,
+ 94D52B6F15D3D313002D6080 /* Localizable.strings */,
932406341077A429008EEF09 /* Info.plist */,
);
name = Resources;
@@ -141,7 +115,7 @@
32C88E010371C26100C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
- 32DBCF630370AF2F00C91783 /* Sample_Prefix.pch */,
+ 32DBCF630370AF2F00C91783 /* MountainGrowl_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "<group>";
@@ -149,53 +123,26 @@
9324062D1077A400008EEF09 /* Growl */ = {
isa = PBXGroup;
children = (
- 932408761077AD8F008EEF09 /* Transitions */,
- 932407F21077AABC008EEF09 /* GrowlDisplayPlugin.h */,
- 932408AE1077AFB0008EEF09 /* GrowlNotificationDisplayBridge.h */,
- 932407FB1077AAF9008EEF09 /* GrowlDisplayWindowController.h */,
- 932407F51077AACC008EEF09 /* GrowlPlugin.h */,
- 932407FE1077AB18008EEF09 /* GrowlPositionController.h */,
- 932407FF1077AB28008EEF09 /* GrowlDefines.h */,
- 932408001077AB28008EEF09 /* GrowlDefinesInternal.h */,
- 932408031077AB5F008EEF09 /* GrowlAbstractSingletonObject.h */,
- 932408341077ABA2008EEF09 /* GrowlPositioningDefines.h */,
- 932408371077ABB5008EEF09 /* NSWindow+Transforms.h */,
- 9324084E1077AC69008EEF09 /* GrowlApplicationNotification.h */,
- 9324088E1077AF4F008EEF09 /* CFDictionaryAdditions.c */,
- 9324088F1077AF4F008EEF09 /* CFDictionaryAdditions.h */,
- 932408931077AF63008EEF09 /* CFGrowlDefines.h */,
- 932408A21077AF86008EEF09 /* GrowlImageAdditions.h */,
- 932408A31077AF86008EEF09 /* GrowlImageAdditions.m */,
+ 94D52BC715D3D5CA002D6080 /* GrowlPluginPreferenceStrings.h */,
+ 94D52BC815D3D5CA002D6080 /* GrowlDisplayPlugin.h */,
+ 94D52BC915D3D5CA002D6080 /* GrowlDisplayWindowController.h */,
+ 94D52BCA15D3D5CA002D6080 /* GrowlNotificationDisplayBridge.h */,
+ 94D52BCC15D3D5E3002D6080 /* GrowlPlugin.h */,
+ 94D52BCD15D3D678002D6080 /* GrowlNotification.h */,
+ 94D52BCE15D3D6EE002D6080 /* GrowlDefines.h */,
+ 94D52BCF15D3D72C002D6080 /* GrowlDefinesInternal.h */,
);
name = Growl;
sourceTree = "<group>";
};
- 932408761077AD8F008EEF09 /* Transitions */ = {
- isa = PBXGroup;
- children = (
- 932408771077AD8F008EEF09 /* GrowlFadingWindowTransition.h */,
- 932408781077AD8F008EEF09 /* GrowlFlippingWindowTransition.h */,
- 932408791077AD8F008EEF09 /* GrowlScaleWindowTransition.h */,
- 9324087A1077AD8F008EEF09 /* GrowlShrinkingWindowTransition.h */,
- 9324087B1077AD8F008EEF09 /* GrowlSlidingWindowTransition.h */,
- 9324087C1077AD8F008EEF09 /* GrowlWindowTransition.h */,
- 9324087D1077AD8F008EEF09 /* GrowlWipeWindowTransition.h */,
- );
- name = Transitions;
- path = source/Growl/Transitions;
- sourceTree = "<group>";
- };
93596AC70A84222E001C6860 /* Source */ = {
isa = PBXGroup;
children = (
- 93596ACC0A84222E001C6860 /* GrowlSampleDisplay.h */,
- 93596ACD0A84222E001C6860 /* GrowlSampleDisplay.m */,
- 93596ACE0A84222E001C6860 /* GrowlSamplePrefs.h */,
- 93596ACF0A84222E001C6860 /* GrowlSamplePrefs.m */,
- 93596AD00A84222E001C6860 /* GrowlSampleWindowController.h */,
- 93596AD10A84222E001C6860 /* GrowlSampleWindowController.m */,
- 93596AD20A84222E001C6860 /* GrowlSampleWindowView.h */,
- 93596AD30A84222E001C6860 /* GrowlSampleWindowView.m */,
+ 946896D015D3D286006577C2 /* MountainGrowlDisplay.h */,
+ 946896D115D3D286006577C2 /* MountainGrowlDisplay.m */,
+ 946896D215D3D286006577C2 /* MountainGrowlPrefs.h */,
+ 946896D315D3D286006577C2 /* MountainGrowlPrefs.m */,
+ 946896D415D3D286006577C2 /* MountainGrowlPrefs.xib */,
);
path = Source;
sourceTree = "<group>";
@@ -226,8 +173,11 @@
/* Begin PBXProject section */
089C1669FE841209C02AAC07 /* Project object */ = {
isa = PBXProject;
+ attributes = {
+ LastUpgradeCheck = 0440;
+ };
buildConfigurationList = 1DEB913E08733D840010E9CD /* Build configuration list for PBXProject "MountainGrowl" */;
- compatibilityVersion = "Xcode 3.1";
+ compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
@@ -254,8 +204,8 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- 932406361077A429008EEF09 /* GrowlSamplePrefs.xib in Resources */,
- 932406371077A429008EEF09 /* InfoPlist.strings in Resources */,
+ 946896D715D3D286006577C2 /* MountainGrowlPrefs.xib in Resources */,
+ 94D52B7115D3D313002D6080 /* Localizable.strings in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -266,35 +216,21 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- 93596AD60A84222E001C6860 /* GrowlSampleDisplay.m in Sources */,
- 93596AD70A84222E001C6860 /* GrowlSamplePrefs.m in Sources */,
- 93596AD80A84222E001C6860 /* GrowlSampleWindowController.m in Sources */,
- 93596AD90A84222E001C6860 /* GrowlSampleWindowView.m in Sources */,
- 932408901077AF4F008EEF09 /* CFDictionaryAdditions.c in Sources */,
- 932408A41077AF86008EEF09 /* GrowlImageAdditions.m in Sources */,
+ 946896D515D3D286006577C2 /* MountainGrowlDisplay.m in Sources */,
+ 946896D615D3D286006577C2 /* MountainGrowlPrefs.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
- 9324062E1077A429008EEF09 /* GrowlSamplePrefs.xib */ = {
- isa = PBXVariantGroup;
- children = (
- 9324062F1077A429008EEF09 /* de */,
- 932406301077A429008EEF09 /* en */,
- 932406331077A429008EEF09 /* fr */,
- 932406351077A429008EEF09 /* ja */,
- );
- name = GrowlSamplePrefs.xib;
- sourceTree = "<group>";
- };
- 932406311077A429008EEF09 /* InfoPlist.strings */ = {
+ 94D52B6F15D3D313002D6080 /* Localizable.strings */ = {
isa = PBXVariantGroup;
children = (
- 932406321077A429008EEF09 /* en */,
+ 94D52B7015D3D313002D6080 /* en */,
+ 94D52B7215D3D31E002D6080 /* de */,
);
- name = InfoPlist.strings;
+ name = Localizable.strings;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */
@@ -303,13 +239,13 @@
1DEB913B08733D840010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
+ COMBINE_HIDPI_IMAGES = YES;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
- GCC_ENABLE_FIX_AND_CONTINUE = YES;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
- GCC_PREFIX_HEADER = source/MountainGrowl_Prefix.pch;
+ GCC_PREFIX_HEADER = MountainGrowl_Prefix.pch;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
INFOPLIST_FILE = resources/Info.plist;
INSTALL_PATH = "$(HOME)/Library/Application Support/Growl/Plugins";
@@ -325,10 +261,11 @@
1DEB913C08733D840010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
+ COMBINE_HIDPI_IMAGES = YES;
GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
- GCC_PREFIX_HEADER = source/MountainGrowl_Prefix.pch;
+ GCC_PREFIX_HEADER = MountainGrowl_Prefix.pch;
INFOPLIST_FILE = resources/Info.plist;
INSTALL_PATH = "$(HOME)/Library/Application Support/Growl/Plugins";
OTHER_LDFLAGS = (
@@ -343,24 +280,24 @@
1DEB913F08733D840010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
- ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
+ ARCHS = "$(ARCHS_STANDARD_64_BIT)";
GCC_ENABLE_OBJC_GC = supported;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- PREBINDING = NO;
- SDKROOT = macosx10.8;
+ MACOSX_DEPLOYMENT_TARGET = 10.8;
+ SDKROOT = macosx;
};
name = Debug;
};
1DEB914008733D840010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
+ ARCHS = "$(ARCHS_STANDARD_64_BIT)";
GCC_ENABLE_OBJC_GC = supported;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- PREBINDING = NO;
- SDKROOT = macosx10.8;
+ MACOSX_DEPLOYMENT_TARGET = 10.8;
+ SDKROOT = macosx;
};
name = Release;
};
View
7 MountainGrowl_Prefix.pch
@@ -0,0 +1,7 @@
+//
+// Prefix header for all source files of the 'Sample' target in the 'Sample' project.
+//
+
+#ifdef __OBJC__
+ #import <Cocoa/Cocoa.h>
+#endif
View
BIN  de.lproj/Localizable.strings
Binary file not shown
View
2  resources/Info.plist
@@ -25,6 +25,6 @@
<key>GrowlPluginDescription</key>
<string>A Growl plugin for Mountian Lions User Notifications</string>
<key>NSPrincipalClass</key>
- <string>GrowlSampleDisplay</string>
+ <string>MountainGrowlDisplay</string>
</dict>
</plist>
View
2,748 resources/de.lproj/GrowlSamplePrefs.xib
0 additions, 2,748 deletions not shown
View
BIN  resources/de.lproj/Localizable.strings
Binary file not shown
View
2,777 resources/en.lproj/GrowlSamplePrefs.xib
0 additions, 2,777 deletions not shown
View
BIN  resources/en.lproj/InfoPlist.strings
Binary file not shown
View
BIN  resources/en.lproj/Localizable.strings
Binary file not shown
View
2,779 resources/fr.lproj/GrowlSamplePrefs.xib
0 additions, 2,779 deletions not shown
View
2,779 resources/ja.lproj/GrowlSamplePrefs.xib
0 additions, 2,779 deletions not shown
View
34 source/Growl/CFDictionaryAdditions.c
@@ -1,34 +0,0 @@
-//
-// CFDictionaryAdditions.c
-// Growl
-//
-// Created by Ingmar Stein on 29.05.05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-
-#include "CFDictionaryAdditions.h"
-
-CFTypeRef getObjectForKey(CFDictionaryRef dict, const void *key) {
- return (CFTypeRef)CFDictionaryGetValue(dict, key);
-}
-
-int getIntegerForKey(CFDictionaryRef dict, const void *key) {
- int value;
- CFNumberRef num = CFDictionaryGetValue(dict, key);
- if (num)
- CFNumberGetValue(num, kCFNumberIntType, &value);
- else
- value = 0;
- return value;
-}
-
-Boolean getBooleanForKey(CFDictionaryRef dict, const void *key) {
- Boolean value;
- CFBooleanRef num = CFDictionaryGetValue(dict, key);
- if (num)
- value = CFBooleanGetValue(num);
- else
- value = false;
- return value;
-}
View
19 source/Growl/CFDictionaryAdditions.h
@@ -1,19 +0,0 @@
-//
-// CFDictionaryAdditions.h
-// Growl
-//
-// Created by Ingmar Stein on 29.05.05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-
-#ifndef HAVE_CFDICTIONARYADDITIONS_H
-#define HAVE_CFDICTIONARYADDITIONS_H
-
-#include "CFGrowlDefines.h"
-
-OBJECT_TYPE getObjectForKey(DICTIONARY_TYPE dict, const void *key);
-int getIntegerForKey(DICTIONARY_TYPE dict, const void *key);
-BOOL_TYPE getBooleanForKey(DICTIONARY_TYPE dict, const void *key);
-
-#endif
View
38 source/Growl/CFGrowlDefines.h
@@ -1,38 +0,0 @@
-//
-// CFURLDefines.h
-// Growl
-//
-// Created by Ingmar Stein on Fri Sep 16 2005.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-
-#ifndef HAVE_CFGROWLDEFINES_H
-#define HAVE_CFGROWLDEFINES_H
-
-#ifdef __OBJC__
-# define DATA_TYPE NSData *
-# define DATE_TYPE NSDate *
-# define DICTIONARY_TYPE NSDictionary *
-# define MUTABLE_DICTIONARY_TYPE NSMutableDictionary *
-# define STRING_TYPE NSString *
-# define ARRAY_TYPE NSArray *
-# define URL_TYPE NSURL *
-# define PLIST_TYPE NSObject *
-# define OBJECT_TYPE id
-# define BOOL_TYPE BOOL
-#else
-# include <CoreFoundation/CoreFoundation.h>
-# define DATA_TYPE CFDataRef
-# define DATE_TYPE CFDateRef
-# define DICTIONARY_TYPE CFDictionaryRef
-# define MUTABLE_DICTIONARY_TYPE CFMutableDictionaryRef
-# define STRING_TYPE CFStringRef
-# define ARRAY_TYPE CFArrayRef
-# define URL_TYPE CFURLRef
-# define PLIST_TYPE CFPropertyListRef
-# define OBJECT_TYPE CFTypeRef
-# define BOOL_TYPE Boolean
-#endif
-
-#endif
View
71 source/Growl/GrowlAbstractSingletonObject.h
@@ -1,71 +0,0 @@
-//
-// GrowlAbstractSingletonObject.h
-// GBUtilities
-//
-// Renamed from GBAbstractSingletonObject to GrowlAbstractSingletonObject.
-// Created by Ofri Wolfus on 15/08/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import <Foundation/Foundation.h>
-
-
-/*!
- * @class GrowlAbstractSingletonObject
- * @brief An Abstract Singleton Object
- *
- * This is an abstract object for object that should have only one instnace
- * that is never released (singleton object).
- * This class is thread safe.
- */
-@interface GrowlAbstractSingletonObject : NSObject {
- BOOL _isInitialized;
-}
-
-/*!
- * @brief Returns the shared instance of this class.
- */
-+ (id) sharedInstance;
-
-/*!
- * @brief Releases and deallocates all the singletons that are subclasses of this object.
- *
- * Once +destroyAllSingletons has been called, no more singletons can be created
- * and every call to [SomeSingletonSubclass sharedInstance] will return nil.
- * Also note that a call to this method will destroy GBAbstractSingletonObject and all it's subclasses.
- * Even though that you generally can't release a singleton object, it's dealloc message WILL be called
- * when it's beeing destroyed.
- *
- * USE THIS METHOD WITH GREAT CAUTION!!!
- */
-+ (void) destroyAllSingletons;
-
-@end
-
-/*!
- * @category GrowlSingletonObjectInit
- * @brief A private category for subclasses only.
- *
- * Only subclasses should override/call methods in the category.
- */
-@interface GrowlAbstractSingletonObject (GrowlAbstractSingletonObjectInit)
-
-/*!
- * @brief An init method for your singleton object.
- *
- * Implement this in your subclass to init your shared object.
- * You should call [super initSingleton] and return your initialized object.
- * Never call this method directly! It'll be automatically called when needed.
- */
-- (id) initSingleton;
-
-/*!
- * @brief Finish and clean up whatever your singleton does.
- *
- * This will be called before the singleton will be destroyed.
- * You should put whatever you would put in the -dealloc method here instead
- * and then call [super destroy].
- */
-- (void) destroy;
-
-@end
View
72 source/Growl/GrowlApplicationNotification.h
@@ -1,72 +0,0 @@
-//
-// GrowlApplicationNotification.h
-// Growl
-//
-// Created by Mac-arena the Bored Zo on 2005-07-31.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-@interface GrowlApplicationNotification: NSObject
-{
- NSString *name, *applicationName;
- NSString *title, *description;
- NSAttributedString *attributedTitle, *attributedDescription;
-
- NSDictionary *dictionary, *auxiliaryDictionary;
-
- unsigned GANReserved: 30;
-}
-
-+ (GrowlApplicationNotification *) notificationWithDictionary:(NSDictionary *)dict;
-
-- (GrowlApplicationNotification *) initWithDictionary:(NSDictionary *)dict;
-
-//you can pass nil for description.
-- (GrowlApplicationNotification *) initWithName:(NSString *)newName
- applicationName:(NSString *)newAppName
- title:(NSString *)newTitle
- description:(NSString *)newDesc;
-
-//you can pass nil for description.
-- (GrowlApplicationNotification *) initWithName:(NSString *)newName
- applicationName:(NSString *)newAppName
- title:(NSString *)newTitle
- description:(NSString *)newDesc;
-
-#pragma mark -
-
-/*as of 0.8, this returns:
- * * GROWL_NOTIFICATION_NAME
- * * GROWL_APP_NAME
- * * GROWL_NOTIFICATION_TITLE
- * * GROWL_NOTIFICATION_DESCRIPTION
- *you can pass this set to -dictionaryRepresentationWithKeys:.
- */
-+ (NSSet *) standardKeys;
-
-//same as dictionaryRepresentationWithKeys:nil.
-- (NSDictionary *) dictionaryRepresentation;
-
-/*with nil, returns all of the standard keys plus the auxiliary dictionary.
- *with non-nil, returns only the keys (from internal storage plus the auxiliary
- * dictionary) that are in the set.
- *in other words, returns the intersection of the standard dictionary keys, the
- * auxiliary dictionary, and the provided keys.
- */
-- (NSDictionary *) dictionaryRepresentationWithKeys:(NSSet *)keys;
-
-#pragma mark -
-
-- (NSString *) name;
-- (NSString *) applicationName;
-
-- (NSString *) title;
-- (NSAttributedString *) attributedTitle;
-
-- (NSString *) notificationDescription;
-- (NSAttributedString *) attributedDescription;
-
-- (NSDictionary *) auxiliaryDictionary;
-- (void) setAuxiliaryDictionary:(NSDictionary *)newAuxDict;
-
-@end
View
20 source/Growl/GrowlImageAdditions.h
@@ -1,20 +0,0 @@
-//
-// GrowlImageAdditions.h
-// Display Plugins
-//
-// Created by Jorge Salvador Caffarena on 20/09/04.
-// Copyright 2004-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-
-#import <Cocoa/Cocoa.h>
-#import "GrowlDefinesInternal.h" // for CGFloat
-
-@interface NSImage (GrowlImageAdditions)
-
-- (void) drawScaledInRect:(NSRect)targetRect operation:(NSCompositingOperation)operation fraction:(CGFloat)f;
-- (NSSize) adjustSizeToDrawAtSize:(NSSize)theSize;
-- (NSImageRep *) bestRepresentationForSize:(NSSize)theSize;
-- (NSImageRep *) representationOfSize:(NSSize)theSize;
-
-@end
View
95 source/Growl/GrowlImageAdditions.m
@@ -1,95 +0,0 @@
-//
-// GrowlImageAdditions.m
-// Display Plugins
-//
-// Created by Jorge Salvador Caffarena on 20/09/04.
-// Copyright 2004-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-
-#import "GrowlImageAdditions.h"
-
-@implementation NSImage (GrowlImageAdditions)
-
-- (void) drawScaledInRect:(NSRect)targetRect operation:(NSCompositingOperation)operation fraction:(CGFloat)f {
- if (!NSEqualSizes([self size], targetRect.size))
- [self adjustSizeToDrawAtSize:targetRect.size];
- NSRect imageRect;
- imageRect.origin.x = 0.0f;
- imageRect.origin.y = 0.0f;
- imageRect.size = [self size];
- if (imageRect.size.width > targetRect.size.width || imageRect.size.height > targetRect.size.height) {
- // make sure the icon isn't too large. If it is, scale it down
- if (imageRect.size.width > imageRect.size.height) {
- CGFloat oldHeight = targetRect.size.height;
- targetRect.size.height = oldHeight / imageRect.size.width * imageRect.size.height;
- targetRect.origin.y = GrowlCGFloatFloor(targetRect.origin.y - (targetRect.size.height - oldHeight) * 0.5f);
- } else if (imageRect.size.width < imageRect.size.height) {
- CGFloat oldWidth = targetRect.size.width;
- targetRect.size.width = oldWidth / imageRect.size.height * imageRect.size.width;
- targetRect.origin.x = GrowlCGFloatFloor(targetRect.origin.x - (targetRect.size.width - oldWidth) * 0.5f);
- }
-
- [self setScalesWhenResized:YES];
- [[NSGraphicsContext currentContext] setImageInterpolation:NSImageInterpolationHigh];
- } else {
- // center image if it is too small
- if (imageRect.size.width < targetRect.size.width)
- targetRect.origin.x += GrowlCGFloatCeiling((targetRect.size.width - imageRect.size.width) * 0.5f);
- if (imageRect.size.height < targetRect.size.height)
- targetRect.origin.y += GrowlCGFloatCeiling((targetRect.size.height - imageRect.size.height) * 0.5f);
- targetRect.size = imageRect.size;
- }
-
- [self drawInRect:targetRect fromRect:imageRect operation:operation fraction:f];
-}
-
-- (NSSize) adjustSizeToDrawAtSize:(NSSize)theSize {
- NSImageRep *bestRep = [self bestRepresentationForSize:theSize];
- NSSize size = [bestRep size];
- [self setSize:size];
- return size;
-}
-
-- (NSImageRep *) bestRepresentationForSize:(NSSize)theSize {
- NSImageRep *bestRep = [self representationOfSize:theSize];
- if (!bestRep) {
- BOOL isFirst = YES;
- CGFloat repDistance = 0.0f;
- NSImageRep *thisRep;
- NSEnumerator *enumerator = [[self representations] objectEnumerator];
- while ((thisRep = [enumerator nextObject])) {
- CGFloat thisDistance = theSize.width - [thisRep size].width;
- if (repDistance < 0.0f && thisDistance > 0.0f)
- continue;
- if (isFirst || GrowlCGFloatAbsoluteValue(thisDistance) < GrowlCGFloatAbsoluteValue(repDistance) || (thisDistance < 0.0 && repDistance > 0.0)) {
- isFirst = NO;
- repDistance = thisDistance;
- bestRep = thisRep;
- }
- }
- }
- if (!bestRep)
- bestRep = [self bestRepresentationForDevice:nil];
-
- return bestRep;
-}
-
-- (NSImageRep *) representationOfSize:(NSSize)theSize {
- NSEnumerator *enumerator = [[self representations] objectEnumerator];
- NSImageRep *rep;
- while ((rep = [enumerator nextObject]))
- if (NSEqualSizes([rep size], theSize))
- break;
- return rep;
-}
-
-// Send NSImages as copies via DO
-- (id) replacementObjectForPortCoder:(NSPortCoder *)encoder {
- if ([encoder isBycopy])
- return self;
- else
- return [super replacementObjectForPortCoder:encoder];
-}
-
-@end
View
114 source/Growl/GrowlPositionController.h
@@ -1,114 +0,0 @@
-//
-// GrowlPositionController.h
-// Growl
-//
-// Created by Ofri Wolfus on 31/08/05.
-// Copyright 2004-2006 The Growl Project. All rights reserved.
-//
-// This file is under the BSD License, refer to License.txt for details
-//
-
-/*!
- * @header GrowlPositionController
- * GrowlPositionController provides a mechanism for display plugins to display without disturbing each other.
- * @copyright Created by Ofri Wolfus on 31/08/05. Copyright 2004-2006 The Growl Project. All rights reserved.
- * @updated 2005-09-18
- * @version 0.8
- */
-
-@class GrowlDisplayWindowController;
-
-#import "GrowlAbstractSingletonObject.h"
-#import "GrowlPositioningDefines.h"
-
-extern NSString *NSStringFromGrowlPosition(enum GrowlPosition pos);
-
-extern NSString *NSStringFromGrowlExpansionDirection(enum GrowlExpansionDirection dir);
-
-/*!
- * @class GrowlPositionController
- * @superclass GrowlAbstractSingletonObject
- * @abstract GrowlPositionController provides a mechanism for display plugins to display without disturbing each other.
- * @discussion GrowlPositionController prevents notifications from covering each other by reserving a rect on the screen which contains the notification.
- * When a rect is reserved, no other notification should be displayed inside this rect (although plugins may ignore this rule).
- * Before a notification is displayed, the display plugin should reserve the rect it's going to use, and clear it when it is done with it.
- * Plugins that uses GrowlDisplayWindowController don't need to worry about contacting GrowlPositionController and reserving rects.
- * GrowlDisplayWindowController takes care for it, but it does require the display plugin to relocate the notification, and display it again.
- */
-@interface GrowlPositionController : GrowlAbstractSingletonObject {
- int selectedPositionType;
- enum GrowlPositionOrigin selectedCustomPosition;
- CFMutableDictionaryRef reservedRects;
-
- NSMutableDictionary *reservedRectsByController;
-}
-
-/*!
- * @method rectForPosition:inScreen:
- * @abstract Returns a rect for a specific position in a specific screen. The rect's size is depended on the resolution and the size of the screen.
- * @param position The position in the specific screen.
- * @param screen The screen which contains the rect of the position. If screen is nil, the main screen will be used.
- */
-+ (NSRect) rectForPosition:(enum GrowlPosition)position inScreen:(NSScreen *)screen;
-
-/*!
- * @method selectedOriginPosition
- * @abstract Reads in the stored selection from picker and translate to a properly returned GrowlPosition.
- * @result GrowlPosition enum. Contains the selected position of one of the enumerated options as translated from the position picker's selection.
- */
-+ (enum GrowlPosition)selectedOriginPosition;
-
-/*!
- * @method positionDisplay
- * @abstract Reserves a rect for a notification in a specific screen.
- * @discussion Preferred method for reserving a rect on the screen
- * Before a notification is displayed, it should reserve the rect of screen it's going to use.
- * When a rect is reserved, no other notification can use it so you must clear it when you're done with it. See
- * clearReservedRectForDisplayController: for doing so.
- * The precise location of displayController may change as a result of this method, which will move it
- * to avoid intersecting with currently reserved rects. Because positionDisplay will only fail if the screen is completely
- * filled with notifications, this is the preferred way to reserve a rect for a display controller.
- * Any previously reserved rect for this displayController will be automatically cleared.
- * @result YES or NO. If the result is NO, you should go watch Heroes reruns instead, as there is currently no way to display a notification.
- */
-- (BOOL) positionDisplay:(GrowlDisplayWindowController *)displayController;
-
-/*!
- * @method reserveRect:inScreen:
- * @abstract Reserves a rect for a notification in a specific screen.
- * @discussion Reserves a rect for a notification.
- * Before a notification is displayed, it should reserve the rect of screen it's going to use.
- * When a rect is reserved, no other notification can use it so you must clear it when you're done with it.
- * A rect will fail to be reserved in the following cases:
- * 1. inRect is not completely inside inScreen.
- * 2. inRect intersects with an already reserved rect.
- * @param inRect The rect that should be reserved.
- * @param inScreen The screen which contains inRect. If inScreen is nil, the main screen will be used.
- * @result YES or NO. If the result is NO, you should display your notification in a different rect/screen.
- */
-- (BOOL) reserveRect:(NSRect)inRect inScreen:(NSScreen *)inScreen forDisplayController:(GrowlDisplayWindowController *)displayController;
-- (BOOL) reserveRect:(NSRect)inRect forDisplayController:(GrowlDisplayWindowController *)displayController;
-
-/*!
- * @method clearReservedRectForDisplayController
- * @abstract Clear the reserved notification rect previously allotted to a display controller
- */
-- (void) clearReservedRectForDisplayController:(GrowlDisplayWindowController *)displayController;
-
-- (enum GrowlPosition) originPosition;
-
-@end
-
-#pragma mark -
-
-@interface NSObject (GrowlPositionControllerProtocol)
-
-/* for the time being this is a simplified version of the protocol. the finished iteration should take
- * into account screen number as well as the types of adjoining displays */
-
-- (NSPoint) idealOriginInRect:(NSRect)rect;
-- (enum GrowlExpansionDirection) primaryExpansionDirection;
-- (enum GrowlExpansionDirection) secondaryExpansionDirection;
-- (CGFloat) requiredDistanceFromExistingDisplays;
-
-@end
View
60 source/Growl/GrowlPositioningDefines.h
@@ -1,60 +0,0 @@
-/*! @header GrowlPositioningDefines.h
-* @abstract Defines all the positioning-related enumerators.
-* @discussion Defines all the positioning-related enumerators for position,
-expansion, and origin selection.
-* @updated 2006-11-24
-*/
-
-/*!
-* @typedef GrowlPosition
- * @abstract Represents a general position on the screen for display plugins.
- *
- * @constant GrowlTopLeftPosition The top left square of the screen.
- * @constant GrowlTopMiddlePosition The top middle square of the screen.
- * @constant GrowlTopRightPosition The top right square of the screen.
- * @constant GrowlCenterLeftPosition The center left square of the screen.
- * @constant GrowlCenterMiddlePosition The center middle square of the screen.
- * @constant GrowlCenterRightPosition The center right square of the screen.
- * @constant GrowlBottomLeftPosition The bottom left square of the screen.
- * @constant GrowlBottomMiddlePosition The bottom left middle of the screen.
- * @constant GrowlBottomRightPosition The bottom right square of the screen.
- * @constant GrowlTopRowPosition The top oblong (row) of the screen.
- * @constant GrowlCenterRowPosition The center oblong (row) of the screen.
- * @constant GrowlBottomRowPosition The bottom oblong (row) of the screen.
- * @constant GrowlLeftColumnPosition The left oblong (column) of the screen.
- * @constant GrowlMiddleColumnPosition The middle oblong (column) of the screen.
- * @constant GrowlRightColumnPosition The right oblong (column) of the screen.
- */
-enum GrowlPosition {
- GrowlTopLeftPosition,
- GrowlTopMiddlePosition,
- GrowlTopRightPosition,
- GrowlCenterLeftPosition,
- GrowlCenterMiddlePosition,
- GrowlCenterRightPosition,
- GrowlBottomLeftPosition,
- GrowlBottomMiddlePosition,
- GrowlBottomRightPosition,
- GrowlTopRowPosition,
- GrowlCenterRowPosition,
- GrowlBottomRowPosition,
- GrowlLeftColumnPosition,
- GrowlMiddleColumnPosition,
- GrowlRightColumnPosition
-};
-
-enum GrowlExpansionDirection {
- GrowlNoExpansionDirection,
- GrowlDownExpansionDirection,
- GrowlUpExpansionDirection,
- GrowlLeftExpansionDirection,
- GrowlRightExpansionDirection
-};
-
-enum GrowlPositionOrigin {
- GrowlNoOrigin,
- GrowlTopLeftCorner,
- GrowlBottomRightCorner,
- GrowlTopRightCorner,
- GrowlBottomLeftCorner
-};
View
34 source/Growl/NSWindow+Transforms.h
@@ -1,34 +0,0 @@
-//
-// NSWindow+Transforms.h
-// Rotated Windows
-//
-// Created by Wade Tregaskis on Fri May 21 2004.
-//
-// Copyright (c) 2004 Wade Tregaskis. All rights reserved.
-// Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
-// * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
-// * Neither the name of Wade Tregaskis nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-#import <AppKit/NSWindow.h>
-#import "GrowlDefinesInternal.h" // for CGFloat
-
-@interface NSWindow (Transforms)
-
-- (NSPoint) windowToScreenCoordinates:(NSPoint)point;
-- (NSPoint) screenToWindowCoordinates:(NSPoint)point;
-
-- (void) rotate:(CGFloat)radians;
-- (void) rotate:(CGFloat)radians about:(NSPoint)point;
-
-- (void) scaleBy:(CGFloat)scaleFactor;
-- (void) scaleX:(CGFloat)x Y:(CGFloat)y;
-- (void) setScaleX:(CGFloat)x Y:(CGFloat)y;
-- (void) scaleX:(CGFloat)x Y:(CGFloat)y about:(NSPoint)point concat:(BOOL)concat;
-
-- (void) reset;
-
-- (void) setSticky:(BOOL)flag;
-@end
View
14 source/Growl/Transitions/GrowlFadingWindowTransition.h
@@ -1,14 +0,0 @@
-//
-// GrowlFadingWindowTransition.h
-// Growl
-//
-// Created by Ofri Wolfus on 27/07/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import "GrowlWindowTransition.h"
-
-@interface GrowlFadingWindowTransition : GrowlWindowTransition {
-}
-
-@end
View
22 source/Growl/Transitions/GrowlFlippingWindowTransition.h
@@ -1,22 +0,0 @@
-//
-// GrowlFlippingWindowTransition.h
-// Growl
-//
-// Created by Jamie Kirkpatrick on 04/12/2005.
-// Copyright 2004-2006 The Growl Project. All rights reserved.
-//
-
-#import "GrowlWindowTransition.h"
-
-@interface GrowlFlippingWindowTransition : GrowlWindowTransition {
- BOOL flipsX;
- BOOL flipsY;
-}
-
-- (BOOL) flipsX;
-- (void) setFlipsX: (BOOL) flag;
-
-- (BOOL) flipsY;
-- (void) setFlipsY: (BOOL) flag;
-
-@end
View
19 source/Growl/Transitions/GrowlScaleWindowTransition.h
@@ -1,19 +0,0 @@
-//
-// GrowlScaleWindowTransition.h
-// Growl
-//
-// Created by rudy on 12/10/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-#import "GrowlWindowTransition.h"
-
-@interface GrowlScaleWindowTransition : GrowlWindowTransition {
- NSPoint startingPoint;
- NSPoint endingPoint;
-}
-
-- (void) setFromOrigin:(NSPoint)from toOrigin:(NSPoint)to;
-- (void) drawTransitionWithWindow:(NSWindow *)aWindow progress:(NSAnimationProgress)progress;
-@end
View
17 source/Growl/Transitions/GrowlShrinkingWindowTransition.h
@@ -1,17 +0,0 @@
-//
-// GrowlShrinkingWindowTransition.h
-// Growl
-//
-// Created by rudy on 12/10/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-
-#import "GrowlWindowTransition.h"
-
-@interface GrowlShrinkingWindowTransition : GrowlWindowTransition {
- CGFloat scaleFactor;
-}
-
-@end
View
22 source/Growl/Transitions/GrowlSlidingWindowTransition.h
@@ -1,22 +0,0 @@
-//
-// GrowlSlidingWindowTransition.h
-// Growl
-//
-// Created by Ofri Wolfus on 21/08/05.
-// Copyright 2005-2006 Ofri Wolfus. All rights reserved.
-//
-
-#import "GrowlWindowTransition.h"
-#import "GrowlDefinesInternal.h" // for CGFloat
-
-@interface GrowlSlidingWindowTransition : GrowlWindowTransition {
- NSPoint startingPoint;
- NSPoint endingPoint;
- CGFloat xDistance;
- CGFloat yDistance;
-}
-
-- (void) setFromOrigin:(NSPoint)startingOrigin toOrigin:(NSPoint)endingOrigin;
-- (void) drawTransitionWithWindow:(NSWindow *)aWindow progress:(NSAnimationProgress)progress;
-
-@end
View
90 source/Growl/Transitions/GrowlWindowTransition.h
@@ -1,90 +0,0 @@
-//
-// GrowlWindowTransition.h
-// Growl
-//
-// Created by Ofri Wolfus on 27/07/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-
-typedef enum {
- GrowlForwardTransition = 0,
- GrowlReverseTransition
-} GrowlTransitionDirection;
-
-/*!
- * @class GrowlWindowTransition
- * @abstract Base class for window transitions.
- */
-@interface GrowlWindowTransition : NSAnimation {
- NSWindow *window;
- GrowlTransitionDirection direction;
- BOOL autoReverses;
- BOOL didAutoReverse;
-}
-
-/* calls initWithWindow:direction: passing GrowlForwardTransition */
-- (id) initWithWindow:(NSWindow *)inWindow;
-
-/*!
- * @method initWithWindow:
- * @abstract Designated initializer.
- * @param inWindow The window for this transition.
- * @param theDirection The initial direction for the transition
- * @result An initialized GrowlWindowTransition instance.
- */
-- (id) initWithWindow:(NSWindow *)inWindow direction:(GrowlTransitionDirection)theDirection;
-
-/*!
-* @method autoReverses
-* @abstract Returns whether the receiver autoreverses its direction on finishing a transition.
-*/
-- (BOOL) autoReverses;
-
-/*!
-* @method setAutoReverses
-* @abstract Sets whether the receiver autoreverses its direction on finishing a transition.
-*/
-- (void) setAutoReverses: (BOOL) flag;
-
-/*!
- * @method reverse
- * @abstract Reverse the receiver
- */
-- (void)reverse;
-
-/*!
-* @method window
-* @abstract Returns the direction of the receiver.
-*/
-- (GrowlTransitionDirection) direction;
-
-/*!
-* @method window
-* @abstract Sets the direction of the receiver.
-*/
-- (void) setDirection: (GrowlTransitionDirection) theDirection;
-
-/*!
- * @method window
- * @abstract Returns the window of the receiver.
- */
-- (NSWindow *) window;
-
-/*!
- * @method setWindow:
- * @abstract Sets the window of the receiver.
- */
-- (void) setWindow:(NSWindow *)inWindow;
-
- //Override this in your subclass in order to draw your animation.
-/*!
- * @method drawTransitionWithWindow:
- * @abstract Overridden by subclasses to draw the receiver’s transition.
- * @discussion This method is called for each frame update.
- * You should override it in your subclass to draw your transition.
- */
-- (void) drawTransitionWithWindow:(NSWindow *)aWindow progress:(NSAnimationProgress)progress;
-
-@end
View
19 source/Growl/Transitions/GrowlWipeWindowTransition.h
@@ -1,19 +0,0 @@
-//
-// GrowlWipeWindowTransition.h
-// Growl
-//
-// Created by rudy on 12/10/05.
-// Copyright 2005-2006 The Growl Project. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-#import "GrowlWindowTransition.h"
-
-@interface GrowlWipeWindowTransition : GrowlWindowTransition {
-
-}
-
-- (void) setFromOrigin:(NSPoint)from toOrigin:(NSPoint)to;
-- (void) drawTransitionWithWindow:(NSWindow *)aWindow progress:(NSAnimationProgress)progress;
-
-@end
View
18 source/GrowlSampleDisplay.h
@@ -1,18 +0,0 @@
-//
-// GrowlSampleDisplay.h
-// Growl Display Plugins
-//
-// Copyright 2006-2009 The Growl Project. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-#import <GrowlDisplayPlugin.h>
-
-@class GrowlApplicationNotification;
-
-@interface GrowlSampleDisplay : GrowlDisplayPlugin {
-}
-
-- (void) configureBridge:(GrowlNotificationDisplayBridge *)theBridge;
-
-@end
View
60 source/GrowlSampleDisplay.m
@@ -1,60 +0,0 @@
-//
-// GrowlSampleDisplay.h
-// Growl Display Plugins
-//
-// Copyright 2006-2009 The Growl Project. All rights reserved.
-//
-
-#import "GrowlSampleDisplay.h"
-#import "GrowlSampleWindowController.h"
-#import "GrowlSamplePrefs.h"
-#import "GrowlApplicationNotification.h"
-#import <GrowlDefinesInternal.h>
-#import <GrowlDefines.h>
-
-@implementation GrowlSampleDisplay
-
-- (id) init {
- if ((self = [super init])) {
- windowControllerClass = NSClassFromString(@"GrowlSampleWindowController");
- }
- return self;
-}
-
-- (void) dealloc {
- [preferencePane release];
- [super dealloc];
-}
-
-- (NSPreferencePane *) preferencePane {
- if (!preferencePane)
- preferencePane = [[GrowlSamplePrefs alloc] initWithBundle:[NSBundle bundleForClass:[GrowlSamplePrefs class]]];
- return preferencePane;
-}
-
-#pragma mark -
-#pragma mark GrowlPositionController Methods
-#pragma mark -
-
-- (BOOL)requiresPositioning {
- return NO;
-}
-
-#pragma mark -
-#pragma mark GAB
-#pragma mark -
-
-- (void) configureBridge:(GrowlNotificationDisplayBridge *)theBridge {
- GrowlSampleWindowController *controller = [[theBridge windowControllers] objectAtIndex:0U];
- GrowlApplicationNotification *note = [theBridge notification];
- NSDictionary *noteDict = [note dictionaryRepresentation];
-
- [controller setNotifyingApplicationName:[note applicationName]];
- [controller setNotifyingApplicationProcessIdentifier:[noteDict objectForKey:GROWL_APP_PID]];
- [controller setClickContext:[noteDict objectForKey:GROWL_NOTIFICATION_CLICK_CONTEXT]];
- [controller setScreenshotModeEnabled:getBooleanForKey(noteDict, GROWL_SCREENSHOT_MODE)];
- [controller setClickHandlerEnabled:[noteDict objectForKey:@"ClickHandlerEnabled"]];
-
-}
-
-@end
View
80 source/GrowlSamplePrefs.h
@@ -1,80 +0,0 @@
-//
-// GrowlSamplePrefs.h
-// Display Plugins
-//
-// Copyright 2006-2009 The Growl Project. All rights reserved.
-//
-
-#import <PreferencePanes/PreferencePanes.h>
-
-#define SamplePrefDomain @"com.Growl.Sample"
-
-#define Sample_SCREEN_PREF @"Screen"
-
-#define Sample_OPACITY_PREF @"Opacity"
-#define Sample_DEFAULT_OPACITY 60.0f
-
-#define Sample_DURATION_PREF @"Duration"
-#define Sample_DEFAULT_DURATION 4.0f
-
-#define Sample_SIZE_PREF @"Size"
-#define Sample_SIZE_NORMAL 0
-#define Sample_SIZE_HUGE 1
-
-#define Sample_EFFECT_PREF @"Transition effect"
-
-typedef enum
-{
- Sample_EFFECT_SLIDE = 0
-} SampleEffectType;
-
-#define GrowlSampleVeryLowBackgroundColor @"Sample-Priority-VeryLow-Color"
-#define GrowlSampleModerateBackgroundColor @"Sample-Priority-Moderate-Color"
-#define GrowlSampleNormalBackgroundColor @"Sample-Priority-Normal-Color"
-#define GrowlSampleHighBackgroundColor @"Sample-Priority-High-Color"
-#define GrowlSampleEmergencyBackgroundColor @"Sample-Priority-Emergency-Color"
-
-#define GrowlSampleVeryLowTextColor @"Sample-Priority-VeryLow-Text-Color"
-#define GrowlSampleModerateTextColor @"Sample-Priority-Moderate-Text-Color"
-#define GrowlSampleNormalTextColor @"Sample-Priority-Normal-Text-Color"
-#define GrowlSampleHighTextColor @"Sample-Priority-High-Text-Color"
-#define GrowlSampleEmergencyTextColor @"Sample-Priority-Emergency-Text-Color"
-
-@interface GrowlSamplePrefs : NSPreferencePane {
- IBOutlet NSSlider *slider_opacity;
-}
-
-- (CGFloat) duration;
-- (void) setDuration:(CGFloat)value;
-- (unsigned) effect;
-- (void) setEffect:(unsigned)newEffect;
-- (CGFloat) opacity;
-- (void) setOpacity:(CGFloat)value;
-- (NSInteger) size;
-- (void) setSize:(NSInteger)value;
-- (NSInteger) screen;
-- (void) setScreen:(NSInteger)value;
-
-- (NSColor *) textColorVeryLow;
-- (void) setTextColorVeryLow:(NSColor *)value;
-- (NSColor *) textColorModerate;
-- (void) setTextColorModerate:(NSColor *)value;
-- (NSColor *) textColorNormal;
-- (void) setTextColorNormal:(NSColor *)value;
-- (NSColor *) textColorHigh;
-- (void) setTextColorHigh:(NSColor *)value;
-- (NSColor *) textColorEmergency;
-- (void) setTextColorEmergency:(NSColor *)value;
-
-- (NSColor *) backgroundColorVeryLow;
-- (void) setBackgroundColorVeryLow:(NSColor *)value;
-- (NSColor *) backgroundColorModerate;
-- (void) setBackgroundColorModerate:(NSColor *)value;
-- (NSColor *) backgroundColorNormal;
-- (void) setBackgroundColorNormal:(NSColor *)value;
-- (NSColor *) backgroundColorHigh;
-- (void) setBackgroundColorHigh:(NSColor *)value;
-- (NSColor *) backgroundColorEmergency;
-- (void) setBackgroundColorEmergency:(NSColor *)value;