Revision: 3310
          http://skim-app.svn.sourceforge.net/skim-app/?rev=3310&view=rev
Author:   hofman
Date:     2007-12-05 03:16:58 -0800 (Wed, 05 Dec 2007)

Log Message:
-----------
Show page number in window title.

Modified Paths:
--------------
    trunk/Dutch.lproj/Localizable.strings
    trunk/French.lproj/Localizable.strings
    trunk/German.lproj/Localizable.strings
    trunk/Italian.lproj/Localizable.strings
    trunk/SKMainWindowController.m
    trunk/Spanish.lproj/Localizable.strings
    trunk/ru.lproj/Localizable.strings

Modified: trunk/Dutch.lproj/Localizable.strings
===================================================================
(Binary files differ)

Modified: trunk/French.lproj/Localizable.strings
===================================================================
(Binary files differ)

Modified: trunk/German.lproj/Localizable.strings
===================================================================
(Binary files differ)

Modified: trunk/Italian.lproj/Localizable.strings
===================================================================
(Binary files differ)

Modified: trunk/SKMainWindowController.m
===================================================================
--- trunk/SKMainWindowController.m      2007-12-04 15:01:39 UTC (rev 3309)
+++ trunk/SKMainWindowController.m      2007-12-05 11:16:58 UTC (rev 3310)
@@ -700,12 +700,9 @@
 }
 
 - (NSString *)windowTitleForDocumentDisplayName:(NSString *)displayName {
-    if ([pdfView document]) {
-        if ([[pdfView document] pageCount] == 1)
-            return [NSString stringWithFormat:NSLocalizedString(@"%@ (1 
page)", @"Window title format"), displayName];
-        else
-            return [NSString stringWithFormat:NSLocalizedString(@"%@ (%i 
pages)", @"Window title format"), displayName, [[pdfView document] pageCount]];
-    } else
+    if ([pdfView document])
+        return [NSString stringWithFormat:NSLocalizedString(@"%@ (page %i of 
%i)", @"Window title format"), displayName, [self pageNumber], [[pdfView 
document] pageCount]];
+    else
         return displayName;
 }
 
@@ -1002,7 +999,7 @@
         }
         
         // the number of pages may have changed
-        [[self window] setTitle:[self windowTitleForDocumentDisplayName:[[self 
document] displayName]]];
+        [mainWindow setTitle:[self windowTitleForDocumentDisplayName:[[self 
document] displayName]]];
         [self updateLeftStatus];
         [self updateRightStatus];
     }
@@ -3168,6 +3165,7 @@
     if (beforeMarkedPageIndex != NSNotFound && [[pdfView currentPage] 
pageIndex] != markedPageIndex)
         beforeMarkedPageIndex = NSNotFound;
     
+    [mainWindow setTitle:[self windowTitleForDocumentDisplayName:[[self 
document] displayName]]];
     [self updateLeftStatus];
 }
 

Modified: trunk/Spanish.lproj/Localizable.strings
===================================================================
(Binary files differ)

Modified: trunk/ru.lproj/Localizable.strings
===================================================================
(Binary files differ)


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

-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell.  From the desktop to the data center, Linux is going
mainstream.  Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to