Revision: 13853
          http://sourceforge.net/p/skim-app/code/13853
Author:   hofman
Date:     2023-12-07 23:19:48 +0000 (Thu, 07 Dec 2023)
Log Message:
-----------
don't bother compiling archiver code path for iOS which is never called

Modified Paths:
--------------
    trunk/SkimNotes/SKNUtilities.m

Modified: trunk/SkimNotes/SKNUtilities.m
===================================================================
--- trunk/SkimNotes/SKNUtilities.m      2023-12-07 15:30:48 UTC (rev 13852)
+++ trunk/SkimNotes/SKNUtilities.m      2023-12-07 23:19:48 UTC (rev 13853)
@@ -290,10 +290,12 @@
 NSData *SKNDataFromSkimNotes(NSArray *noteDicts, BOOL asPlist) {
     NSData *data = nil;
     if (noteDicts) {
-#if defined(PDFKIT_PLATFORM_IOS)
-        asPlist = YES;
+#if !defined(PDFKIT_PLATFORM_IOS)
+        if (asPlist == NO) {
+            data = [NSKeyedArchiver archivedDataWithRootObject:noteDicts];
+        } else
 #endif
-        if (asPlist) {
+        {
             NSMutableArray *array = [[NSMutableArray alloc] init];
             NSMapTable *colors = [[NSMapTable alloc] 
initWithKeyOptions:NSPointerFunctionsStrongMemory | 
NSPointerFunctionsObjectPersonality valueOptions:NSPointerFunctionsStrongMemory 
| NSPointerFunctionsObjectPersonality capacity:0];
             for (NSDictionary *noteDict in noteDicts) {
@@ -354,8 +356,6 @@
                 [array addObject:dict];
             }
             data = [NSPropertyListSerialization dataWithPropertyList:array 
format:NSPropertyListBinaryFormat_v1_0 options:0 error:NULL];
-        } else {
-            data = [NSKeyedArchiver archivedDataWithRootObject:noteDicts];
         }
     }
     return data;

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



_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to