Revision: 26883
          http://sourceforge.net/p/bibdesk/svn/26883
Author:   hofman
Date:     2021-09-15 09:16:19 +0000 (Wed, 15 Sep 2021)
Log Message:
-----------
Use block based sheet method

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

Modified: trunk/bibdesk/BDSKPersonController.m
===================================================================
--- trunk/bibdesk/BDSKPersonController.m        2021-09-15 09:14:53 UTC (rev 
26882)
+++ trunk/bibdesk/BDSKPersonController.m        2021-09-15 09:16:19 UTC (rev 
26883)
@@ -453,12 +453,14 @@
     [editField setStringValue:[newAuthor name]];
     [editField selectText:self];
     
-    [NSApp beginSheet:editSheet
-          modalForWindow:[self window]
-               modalDelegate:self
-          didEndSelector:@selector(editSheetDidEnd:returnCode:contextInfo:)
-                 contextInfo:NULL];
-
+    [[self window] beginSheet:editSheet completionHandler:^(NSInteger result){
+        if (result == NSOKButton) {
+            NSString *newName = [editField stringValue];
+            if ([NSString isEmptyString:newName] == NO)
+                [self changeNameToString:newName];
+        }
+    }];
+    
     return YES;
 }
 

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



_______________________________________________
Bibdesk-commit mailing list
Bibdesk-commit@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to