Revision: 27890
          http://sourceforge.net/p/bibdesk/svn/27890
Author:   hofman
Date:     2022-09-15 14:41:53 +0000 (Thu, 15 Sep 2022)
Log Message:
-----------
remove observer for font size key

Modified Paths:
--------------
    trunk/bibdesk/BDSKEditorTextView.m

Modified: trunk/bibdesk/BDSKEditorTextView.m
===================================================================
--- trunk/bibdesk/BDSKEditorTextView.m  2022-09-15 06:30:38 UTC (rev 27889)
+++ trunk/bibdesk/BDSKEditorTextView.m  2022-09-15 14:41:53 UTC (rev 27890)
@@ -82,7 +82,7 @@
     if (usesDefaultFont)
         BDSKENSURE_MAIN_THREAD(
             @try {
-            [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontSizeKey] 
context:&BDSKEditorTextViewDefaultsObservationContext];
+                [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontSizeKey] 
context:&BDSKEditorTextViewDefaultsObservationContext];
                 [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontNameKey] 
context:&BDSKEditorTextViewDefaultsObservationContext];
             }
             @catch (id e) {}
@@ -105,9 +105,11 @@
                    options:0
                    context:&BDSKEditorTextViewDefaultsObservationContext];
         } else {
-            [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self
-                    forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontNameKey]
-                       context:&BDSKEditorTextViewDefaultsObservationContext];
+            @try {
+                [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontSizeKey] 
context:&BDSKEditorTextViewDefaultsObservationContext];
+                [[NSUserDefaultsController sharedUserDefaultsController] 
removeObserver:self forKeyPath:[@"values." 
stringByAppendingString:BDSKEditorFontNameKey] 
context:&BDSKEditorTextViewDefaultsObservationContext];
+            }
+            @catch (id e) {}
         }
     }
 }

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



_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to