Revision: 5915
          http://skim-app.svn.sourceforge.net/skim-app/?rev=5915&view=rev
Author:   hofman
Date:     2009-10-20 11:20:31 +0000 (Tue, 20 Oct 2009)

Log Message:
-----------
run runloop until expected end date of fullscreen fade out animation

Modified Paths:
--------------
    trunk/SKMainWindowController.m

Modified: trunk/SKMainWindowController.m
===================================================================
--- trunk/SKMainWindowController.m      2009-10-20 10:11:28 UTC (rev 5914)
+++ trunk/SKMainWindowController.m      2009-10-20 11:20:31 UTC (rev 5915)
@@ -1576,6 +1576,7 @@
     NSView *view = [self isFullScreen] ? (NSView *)pdfSplitView : (NSView 
*)pdfView;
     NSView *contentView = [view superview];
     NSDate *limitDate = [NSDate dateWithTimeIntervalSinceNow:3.5];
+    NSDate *endDate;
     CAAnimation *animation = [CATransition animation];
     
     // 10.5 has problems animating with a transparent background
@@ -1588,9 +1589,10 @@
     [contentView setWantsLayer:YES];
     [contentView displayIfNeeded];
     mwcFlags.isFadingOut = 1;
+    endDate = [NSDate dateWithTimeIntervalSinceNow:0.5];
     [[view animator] removeFromSuperview];
     while (mwcFlags.isFadingOut && [limitDate compare:[NSDate date]] != 
NSOrderedAscending)
-        [[NSRunLoop currentRunLoop] runUntilDate:[NSDate distantPast]];
+        [[NSRunLoop currentRunLoop] runUntilDate:endDate];
     mwcFlags.isFadingOut = 0;
     [contentView setWantsLayer:NO];
     [contentView setAnimations:nil];


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to