Frameworks/Adium Framework/Source/AIDockControllerProtocol.h
author Frank Dowsett <wixardy@adium.im>
Fri, 18 Feb 2011 15:44:06 -0500
changeset 3670 add0c83648a5
parent 3 f0cc4d307eb8
child 3679 f4294bb53b0f
permissions -rw-r--r--
Massive changes to dock icon drawing:
- Use NSDockTile for badging fixes #13439
- Remove flashing of the contact name* fixes #14452
- Use a constant size instead of the current screen's size fixes #13088

Fixes #616

*It's superfluous and may have been broken in 1.3 based on the reports from after 1.4 was released.
/*
 *  AIDockControllerProtocol.h
 *  Adium
 *
 *  Created by Evan Schoenberg on 7/31/06.
 *
 */

#import <Adium/AIControllerProtocol.h>

#define PREF_GROUP_APPEARANCE		@"Appearance"

#define KEY_ACTIVE_DOCK_ICON		@"Dock Icon"
#define FOLDER_DOCK_ICONS			@"Dock Icons"

#define KEY_ANIMATE_DOCK_ICON		@"Animate Dock Icon on Unread Messages"
#define KEY_BADGE_DOCK_ICON			@"Badge Dock Icon on Unread Messages"

@class AIIconState;

typedef enum {
    AIDockBehaviorStopBouncing = 0,
    AIDockBehaviorBounceOnce,
    AIDockBehaviorBounceRepeatedly,
    AIDockBehaviorBounceDelay_FiveSeconds,
    AIDockBehaviorBounceDelay_TenSeconds,
    AIDockBehaviorBounceDelay_FifteenSeconds,
    AIDockBehaviorBounceDelay_ThirtySeconds,
    AIDockBehaviorBounceDelay_OneMinute
} AIDockBehavior;

@protocol AIDockController <AIController>
//Icon animation & states
- (void)setIconStateNamed:(NSString *)inName;
- (void)removeIconStateNamed:(NSString *)inName;
- (void)setIconState:(AIIconState *)iconState named:(NSString *)inName;
- (NSImage *)baseApplicationIconImage;
- (void)setOverlay:(NSImage *)image;

//Special access to icon pack loading
- (NSArray *)availableDockIconPacks;
- (BOOL)currentIconSupportsIconStateNamed:(NSString *)inName;
- (NSMutableDictionary *)iconPackAtPath:(NSString *)folderPath;
- (void)getName:(NSString **)outName previewState:(AIIconState **)outIconState forIconPackAtPath:(NSString *)folderPath;
- (AIIconState *)previewStateForIconPackAtPath:(NSString *)folderPath;

//Bouncing & behavior
- (BOOL)performBehavior:(AIDockBehavior)behavior;
- (NSString *)descriptionForBehavior:(AIDockBehavior)behavior;
@end