Revision: 2589
          http://skim-app.svn.sourceforge.net/skim-app/?rev=2589&view=rev
Author:   hofman
Date:     2007-07-30 09:22:12 -0700 (Mon, 30 Jul 2007)

Log Message:
-----------
Make sure text edits are committed before closing the pref window or changing 
the tab item.

Modified Paths:
--------------
    trunk/Dutch.lproj/PreferenceWindow.nib/info.nib
    trunk/Dutch.lproj/PreferenceWindow.nib/keyedobjects.nib
    trunk/English.lproj/PreferenceWindow.nib/keyedobjects.nib
    trunk/French.lproj/PreferenceWindow.nib/keyedobjects.nib
    trunk/Italian.lproj/PreferenceWindow.nib/keyedobjects.nib
    trunk/SKPreferenceController.m

Modified: trunk/Dutch.lproj/PreferenceWindow.nib/info.nib
===================================================================
--- trunk/Dutch.lproj/PreferenceWindow.nib/info.nib     2007-07-30 16:10:03 UTC 
(rev 2588)
+++ trunk/Dutch.lproj/PreferenceWindow.nib/info.nib     2007-07-30 16:22:12 UTC 
(rev 2589)
@@ -8,6 +8,10 @@
        <string>446.1</string>
        <key>IBLockedObjects</key>
        <array/>
+       <key>IBOpenObjects</key>
+       <array>
+               <integer>5</integer>
+       </array>
        <key>IBSystem Version</key>
        <string>8R218</string>
 </dict>

Modified: trunk/Dutch.lproj/PreferenceWindow.nib/keyedobjects.nib
===================================================================
(Binary files differ)

Modified: trunk/English.lproj/PreferenceWindow.nib/keyedobjects.nib
===================================================================
(Binary files differ)

Modified: trunk/French.lproj/PreferenceWindow.nib/keyedobjects.nib
===================================================================
(Binary files differ)

Modified: trunk/Italian.lproj/PreferenceWindow.nib/keyedobjects.nib
===================================================================
(Binary files differ)

Modified: trunk/SKPreferenceController.m
===================================================================
--- trunk/SKPreferenceController.m      2007-07-30 16:10:03 UTC (rev 2588)
+++ trunk/SKPreferenceController.m      2007-07-30 16:22:12 UTC (rev 2589)
@@ -180,6 +180,18 @@
     [[[self window] contentView] deactivateColorAndLineWells];
 }
 
+- (void)windowWillClose:(NSNotification *)notification {
+    // make sure edits are committed
+    if ([[[self window] firstResponder] isKindOfClass:[NSText class]] && 
[[self window] makeFirstResponder:[self window]] == NO)
+        [[self window] endEditingFor:nil];
+}
+
+- (void)tabView:(NSTabView *)tabView willSelectTabViewItem:(NSTabViewItem 
*)tabViewItem {
+    // make sure edits are committed
+    if ([[[self window] firstResponder] isKindOfClass:[NSText class]] && 
[[self window] makeFirstResponder:[self window]] == NO)
+        [[self window] endEditingFor:nil];
+}
+
 - (NSArray *)fonts {
     return fonts;
 }


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: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to