Revision: 28327
          http://sourceforge.net/p/bibdesk/svn/28327
Author:   hofman
Date:     2023-07-19 15:58:31 +0000 (Wed, 19 Jul 2023)
Log Message:
-----------
use NSChangeReadOtherContents and set displayName when opening document with 
filter or tmp keys

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

Modified: trunk/bibdesk/BibDocument.m
===================================================================
--- trunk/bibdesk/BibDocument.m 2023-07-18 14:25:44 UTC (rev 28326)
+++ trunk/bibdesk/BibDocument.m 2023-07-19 15:58:31 UTC (rev 28327)
@@ -1975,7 +1975,10 @@
 #pragma mark -
 
 - (void)markAsImported {
+    NSString *fileName = [[[self fileURL] lastPathComponent] 
stringByDeletingPathExtension];
     [self setFileURL:nil];
+    if (fileName)
+        [self setDisplayName:fileName];
     // set date-added for imports
     NSDate *importDate = [NSDate date];
     NSString *importDateDescription = [importDate standardDescription];
@@ -1983,7 +1986,7 @@
         [pub markNeWithDate:importDate description:importDateDescription];
     [[self undoManager] removeAllActions];
     // mark as dirty, since we've changed the content
-    [self updateChangeCount:NSChangeDone];
+    [self updateChangeCount:NSChangeReadOtherContents];
 }
 
 - (void)generateForTemporaryCiteKey:(NSString *)tmpKey {

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