Revision: 14974
          http://sourceforge.net/p/skim-app/code/14974
Author:   hofman
Date:     2025-03-15 17:04:23 +0000 (Sat, 15 Mar 2025)
Log Message:
-----------
hidden preference to disable changing the zoom from goToDestination

Modified Paths:
--------------
    trunk/SKBasePDFView.m

Modified: trunk/SKBasePDFView.m
===================================================================
--- trunk/SKBasePDFView.m       2025-03-14 15:48:23 UTC (rev 14973)
+++ trunk/SKBasePDFView.m       2025-03-15 17:04:23 UTC (rev 14974)
@@ -46,6 +46,8 @@
 #import "PDFPage_SKExtensions.h"
 #import "PDFDestination_SKExtensions.h"
 
+#define SKNeverChangeZoomFromLinksKey @"SKNeverChangeZoomFromLinks"
+
 static char SKBasePDFViewDefaultsObservationContext;
 
 #if SDK_BEFORE_10_14
@@ -351,7 +353,7 @@
 
 - (void)goToDestination:(PDFDestination *)destination {
     destination = [destination effectiveDestinationForView:self];
-    if ([destination zoom] < kPDFDestinationUnspecifiedValue && [destination 
zoom] > 0.0)
+    if ([destination zoom] < kPDFDestinationUnspecifiedValue && [destination 
zoom] > 0.0 && [[NSUserDefaults standardUserDefaults] 
boolForKey:SKNeverChangeZoomFromLinksKey] == NO)
         [self setScaleFactor:[destination zoom]];
     [super goToDestination:destination];
 }

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



_______________________________________________
Skim-app-commit mailing list
Skim-app-commit@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to