Builds now. Also some moderate effect architecture changes.
[ITKit.git] / ITWindowEffect.h
1 /*
2  *      ITKit
3  *  ITWindowEffect
4  *    Protocal and abstract superclass for performing effects on windows.
5  *
6  *  Original Author : Matt Judy <mjudy@ithinksw.com>
7  *   Responsibility : Matt Judy <mjudy@ithinksw.com>
8  *
9  *  Copyright (c) 2002 - 2003 iThink Software.
10  *  All Rights Reserved
11  *
12  */
13
14
15 #import <Cocoa/Cocoa.h>
16 #import "ITWindowPositioning.h"
17
18
19 #define EFFECT_FPS 30.0
20 #define DEFAULT_EFFECT_TIME 0.75
21
22
23 @protocol ITWindowEffect
24
25 - (void)performAppear;
26 - (void)performVanish;
27
28 @end
29
30
31 @interface ITWindowEffect : NSObject <ITWindowEffect>
32 {
33     NSWindow                   *_window;
34     float                       _effectTime;
35     double                      _effectProgress;
36     ITVerticalWindowPosition    _verticalPosition;
37     ITHorizontalWindowPosition  _horizontalPosition;
38     NSTimer                    *_effectTimer;
39 }
40
41 // Designated initializer
42 - (id)initWithWindow:(NSWindow *)window;
43
44 - (NSWindow *)window;
45
46 // setWindow: does not retain or release its window.  It simply references it.
47 - (void)setWindow:(NSWindow *)newWindow;
48
49 @end