git.ithinksw.org
/
ITKit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Moving to the new means of setting the window visibility state: allowing the effects...
[ITKit.git]
/
ITPivotWindowEffect.m
diff --git
a/ITPivotWindowEffect.m
b/ITPivotWindowEffect.m
index
299506a
..
52b2858
100755
(executable)
--- a/
ITPivotWindowEffect.m
+++ b/
ITPivotWindowEffect.m
@@
-1,16
+1,21
@@
#import "ITPivotWindowEffect.h"
#import "ITCoreGraphicsHacks.h"
#import "ITPivotWindowEffect.h"
#import "ITCoreGraphicsHacks.h"
+#import "ITTransientStatusWindow.h"
+
@interface ITPivotWindowEffect (Private)
- (void)setPivot:(float)angle;
@interface ITPivotWindowEffect (Private)
- (void)setPivot:(float)angle;
-- (void)pivotFinish;
+- (void)appearFinish;
+- (void)vanishFinish;
@end
@end
-@implementation ITPivotWindowEffect
+@implementation ITPivotWindowEffect
- (void)performAppear
{
- (void)performAppear
{
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowAppearingState];
[self setPivot:315.0];
_effectProgress = 0.0;
[_window setAlphaValue:0.0];
[self setPivot:315.0];
_effectProgress = 0.0;
[_window setAlphaValue:0.0];
@@
-24,6
+29,8
@@
- (void)performVanish
{
- (void)performVanish
{
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowVanishingState];
[self setPivot:0.0];
_effectProgress = 1.0;
[_window setAlphaValue:1.0];
[self setPivot:0.0];
_effectProgress = 1.0;
[_window setAlphaValue:1.0];
@@
-37,19
+44,23
@@
- (void)cancelAppear
{
- (void)cancelAppear
{
- [self
pivot
Finish];
+ [self
appear
Finish];
[_window orderOut:self];
[self setPivot:0.0];
[_window setAlphaValue:1.0];
[_window orderOut:self];
[self setPivot:0.0];
[_window setAlphaValue:1.0];
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowHiddenState];
}
- (void)cancelVanish
{
}
- (void)cancelVanish
{
- [self
pivot
Finish];
+ [self
vanish
Finish];
[self setPivot:0.0];
[_window setAlphaValue:1.0];
[_window orderFront:self];
[_window display];
[self setPivot:0.0];
[_window setAlphaValue:1.0];
[_window orderFront:self];
[_window display];
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowVisibleState];
}
- (void)appearStep
}
- (void)appearStep
@@
-62,7
+73,7
@@
[_window setAlphaValue:interPivot];
if ( _effectProgress >= 1.0 ) {
[_window setAlphaValue:interPivot];
if ( _effectProgress >= 1.0 ) {
- [self
pivot
Finish];
+ [self
appear
Finish];
}
}
}
}
@@
-76,16
+87,25
@@
[_window setAlphaValue:interPivot];
if ( _effectProgress <= 0.0 ) {
[_window setAlphaValue:interPivot];
if ( _effectProgress <= 0.0 ) {
- [self
pivot
Finish];
+ [self
vanish
Finish];
}
}
}
}
-- (void)
pivot
Finish
+- (void)
appear
Finish
{
[_effectTimer invalidate];
_effectTimer = nil;
{
[_effectTimer invalidate];
_effectTimer = nil;
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowVisibleState];
}
}
+- (void)vanishFinish
+{
+ [_effectTimer invalidate];
+ _effectTimer = nil;
+ // Cast so the compiler won't gripe
+ [(ITTransientStatusWindow *)_window setVisibilityState:ITTransientStatusWindowHiddenState];
+}
- (void)setPivot:(float)angle
{
- (void)setPivot:(float)angle
{