Revision: 5539
          http://skim-app.svn.sourceforge.net/skim-app/?rev=5539&view=rev
Author:   hofman
Date:     2009-08-12 10:02:33 +0000 (Wed, 12 Aug 2009)

Log Message:
-----------
disable the revert script command when we're auto-updating

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

Modified: trunk/SKPDFDocument.m
===================================================================
--- trunk/SKPDFDocument.m       2009-08-12 09:50:12 UTC (rev 5538)
+++ trunk/SKPDFDocument.m       2009-08-12 10:02:33 UTC (rev 5539)
@@ -2280,7 +2280,10 @@
 
 - (void)handleRevertScriptCommand:(NSScriptCommand *)command {
     id document = [[self windowController] document];
-    if (document == nil) {
+    if (docFlags.isUpdatingFile) {
+        [command setScriptErrorNumber:NSInternalScriptError];
+        [command setScriptErrorString:@"Cannot revert."];
+    } else if (document == nil) {
         [command setScriptErrorNumber:NSArgumentsWrongScriptError];
         [command setScriptErrorString:@"Window does not have a document."];
     } else


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

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to