Revision: 4444
          http://skim-app.svn.sourceforge.net/skim-app/?rev=4444&view=rev
Author:   hofman
Date:     2008-08-23 23:05:14 +0000 (Sat, 23 Aug 2008)

Log Message:
-----------
Pass window nib name in initializer for singleton window controllers

Modified Paths:
--------------
    trunk/SKBookmarkController.m
    trunk/SKFindController.m
    trunk/SKInfoWindowController.m
    trunk/SKPreferenceController.m
    trunk/SKReleaseNotesController.m

Modified: trunk/SKBookmarkController.m
===================================================================
--- trunk/SKBookmarkController.m        2008-08-23 18:06:57 UTC (rev 4443)
+++ trunk/SKBookmarkController.m        2008-08-23 23:05:14 UTC (rev 4444)
@@ -110,7 +110,7 @@
 }
 
 - (id)init {
-    if (sharedBookmarkController == nil && (sharedBookmarkController = self = 
[super init])) {
+    if (sharedBookmarkController == nil && (sharedBookmarkController = self = 
[super initWithWindowNibName:@"BookmarksWindow"])) {
         recentDocuments = [[NSMutableArray alloc] init];
         
         NSMutableArray *bookmarks = [NSMutableArray array];
@@ -170,8 +170,6 @@
 
 - (unsigned)retainCount { return UINT_MAX; }
 
-- (NSString *)windowNibName { return @"BookmarksWindow"; }
-
 - (void)windowDidLoad {
     [self setupToolbar];
     

Modified: trunk/SKFindController.m
===================================================================
--- trunk/SKFindController.m    2008-08-23 18:06:57 UTC (rev 4443)
+++ trunk/SKFindController.m    2008-08-23 23:05:14 UTC (rev 4444)
@@ -56,7 +56,7 @@
 }
 
 - (id)init {
-    if (sharedFindController == nil && (sharedFindController = self = [super 
init])) {
+    if (sharedFindController == nil && (sharedFindController = self = [super 
initWithWindowNibName:@"FindPanel"])) {
         ignoreCase = YES;
     }
     return sharedFindController;
@@ -75,8 +75,6 @@
 
 - (unsigned)retainCount { return UINT_MAX; }
 
-- (NSString *)windowNibName { return @"FindPanel"; }
-
 - (void)awakeFromNib {
     if (self == sharedFindController)
         [self setWindowFrameAutosaveName:SKFindPanelFrameAutosaveName];

Modified: trunk/SKInfoWindowController.m
===================================================================
--- trunk/SKInfoWindowController.m      2008-08-23 18:06:57 UTC (rev 4443)
+++ trunk/SKInfoWindowController.m      2008-08-23 23:05:14 UTC (rev 4444)
@@ -78,7 +78,7 @@
 }
 
 - (id)init {
-    if (sharedInstance == nil && (sharedInstance = self = [super init])) {
+    if (sharedInstance == nil && (sharedInstance = self = [super 
initWithWindowNibName:@"InfoWindow"])) {
         info = [[NSMutableDictionary alloc] init];
     }
     return sharedInstance;
@@ -98,10 +98,6 @@
 
 - (unsigned)retainCount { return UINT_MAX; }
 
-- (NSString *)windowNibName {
-    return @"InfoWindow";
-}
-
 - (void)windowDidLoad {
     [self setWindowFrameAutosaveName:SKInfoWindowFrameAutosaveName];
     

Modified: trunk/SKPreferenceController.m
===================================================================
--- trunk/SKPreferenceController.m      2008-08-23 18:06:57 UTC (rev 4443)
+++ trunk/SKPreferenceController.m      2008-08-23 23:05:14 UTC (rev 4444)
@@ -70,7 +70,7 @@
 }
 
 - (id)init {
-    if (sharedPrefenceController == nil && (sharedPrefenceController = self = 
[super init])) {
+    if (sharedPrefenceController == nil && (sharedPrefenceController = self = 
[super initWithWindowNibName:@"PreferenceWindow"])) {
         NSString *initialUserDefaultsPath = [[NSBundle mainBundle] 
pathForResource:SKPreferenceInitialUserDefaultsFileName ofType:@"plist"];
         resettableKeys = [[[NSDictionary 
dictionaryWithContentsOfFile:initialUserDefaultsPath] 
valueForKey:SKPreferenceResettableKeysKey] retain];
         
@@ -95,10 +95,6 @@
 
 - (unsigned)retainCount { return UINT_MAX; }
 
-- (NSString *)windowNibName {
-    return @"PreferenceWindow";
-}
-
 - (void)updateRevertButtons {
     NSDictionary *initialValues = [sudc initialValues];
     [revertPDFSettingsButton setEnabled:[[initialValues 
objectForKey:SKDefaultPDFDisplaySettingsKey] isEqual:[sud 
dictionaryForKey:SKDefaultPDFDisplaySettingsKey]] == NO];

Modified: trunk/SKReleaseNotesController.m
===================================================================
--- trunk/SKReleaseNotesController.m    2008-08-23 18:06:57 UTC (rev 4443)
+++ trunk/SKReleaseNotesController.m    2008-08-23 23:05:14 UTC (rev 4444)
@@ -53,7 +53,7 @@
 
 - (id)init {
     if (sharedReleaseNotesController == nil) {
-        sharedReleaseNotesController = [super init];
+        sharedReleaseNotesController = [super 
initWithWindowNibName:@"ReleaseNotes"];
     }
     return sharedReleaseNotesController;
 }
@@ -66,10 +66,6 @@
 
 - (unsigned)retainCount { return UINT_MAX; }
 
-- (NSString *)windowNibName {
-    return @"ReleaseNotes";
-}
-
 - (void)windowDidLoad {
     [textView setString:@""];
     [textView replaceCharactersInRange:[textView selectedRange]


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

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to