Revision: 15910
          http://sourceforge.net/p/skim-app/code/15910
Author:   hofman
Date:     2025-12-23 10:38:43 +0000 (Tue, 23 Dec 2025)
Log Message:
-----------
rename methods for our destination

Modified Paths:
--------------
    trunk/PDFView_SKExtensions.h
    trunk/PDFView_SKExtensions.m
    trunk/SKMainDocument.m
    trunk/SKMainWindowController.m
    trunk/SKMainWindowController_Actions.m

Modified: trunk/PDFView_SKExtensions.h
===================================================================
--- trunk/PDFView_SKExtensions.h        2025-12-23 10:34:21 UTC (rev 15909)
+++ trunk/PDFView_SKExtensions.h        2025-12-23 10:38:43 UTC (rev 15910)
@@ -67,8 +67,8 @@
 
 - (nullable PDFPage *)pageAndPoint:(NSPoint * _Nullable)point 
forEvent:(NSEvent *)event nearest:(BOOL)nearest;
 
-- (SKDestination)currentDestination:(BOOL)invalidatePointWhenRotated;
-- (void)goToCurrentDestination:(SKDestination)destination;
+- (SKDestination)skDestination:(BOOL)invalidatePointWhenRotated;
+- (void)goToSKDestination:(SKDestination)destination;
 
 - (void)goAndScrollToPage:(PDFPage *)page;
 

Modified: trunk/PDFView_SKExtensions.m
===================================================================
--- trunk/PDFView_SKExtensions.m        2025-12-23 10:34:21 UTC (rev 15909)
+++ trunk/PDFView_SKExtensions.m        2025-12-23 10:38:43 UTC (rev 15910)
@@ -195,7 +195,7 @@
     return page;
 }
 
-- (SKDestination)currentDestination:(BOOL)invalidatePointWhenRotated {
+- (SKDestination)skDestination:(BOOL)invalidatePointWhenRotated {
     PDFPage *page = [self currentPage];
     NSPoint point = SKUnspecifiedPoint;
     if ([[page document] isLocked] == NO && (invalidatePointWhenRotated == NO 
|| [page rotation] == [page intrinsicRotation])) {
@@ -207,7 +207,7 @@
     return (SKDestination){[page pageIndex], point};
 }
 
-- (void)goToCurrentDestination:(SKDestination)dest {
+- (void)goToSKDestination:(SKDestination)dest {
     PDFPage *page = [[self document] pageAtIndex:dest.pageIndex];
     if (NSEqualPoints(dest.point, SKUnspecifiedPoint)) {
         [self goAndScrollToPage:page];

Modified: trunk/SKMainDocument.m
===================================================================
--- trunk/SKMainDocument.m      2025-12-23 10:34:21 UTC (rev 15909)
+++ trunk/SKMainDocument.m      2025-12-23 10:38:43 UTC (rev 15910)
@@ -272,7 +272,7 @@
                 pointString = [NSString stringWithFormat:@"{%@}", pointString];
             dest.pageIndex = page - 1;
             dest.point = NSPointFromString(pointString);
-            [pdfView goToCurrentDestination:dest];
+            [pdfView goToSKDestination:dest];
         } else if ((NSInteger)[[pdfView currentPage] pageIndex] != page) {
             [pdfView goAndScrollToPage:[[pdfView document] pageAtIndex:page - 
1]];
         }
@@ -1780,7 +1780,7 @@
 }
 
 - (NSData *)currentQDPoint {
-    SKDestination dest = [[self pdfView] currentDestination:NO];
+    SKDestination dest = [[self pdfView] skDestination:NO];
     Point qdPoint = SKQDPointFromNSPoint(dest.point);
     return [NSData dataWithBytes:&qdPoint length:sizeof(Point)];
 }

Modified: trunk/SKMainWindowController.m
===================================================================
--- trunk/SKMainWindowController.m      2025-12-23 10:34:21 UTC (rev 15909)
+++ trunk/SKMainWindowController.m      2025-12-23 10:38:43 UTC (rev 15910)
@@ -485,7 +485,7 @@
         if ([[pdfView document] isLocked]) {
             [self setDestination:dest inSetup:savedNormalSetup];
         } else if ([[pdfView currentPage] pageIndex] != dest.pageIndex || 
NSEqualPoints(dest.point, SKUnspecifiedPoint) == NO) {
-            [pdfView goToCurrentDestination:dest];
+            [pdfView goToSKDestination:dest];
             [lastViewedPages setCount:0];
             [lastViewedPages addPointer:(void *)dest.pageIndex];
             [pdfView resetHistory];
@@ -604,7 +604,7 @@
             
             SKDestination dest = [self destinationFromSetup:setup];
             if (dest.pageIndex != NSNotFound && dest.pageIndex != [[pdfView 
currentPage] pageIndex])
-                [pdfView goToCurrentDestination:dest];
+                [pdfView goToSKDestination:dest];
         }
     }
 }
@@ -611,7 +611,7 @@
 
 - (NSDictionary *)currentSetup {
     NSMutableDictionary *setup = [NSMutableDictionary dictionary];
-    SKDestination dest = [pdfView currentDestination:YES];
+    SKDestination dest = [pdfView skDestination:YES];
     NSArray *cropBoxes = [[self pdfDocument] changedCropBoxes];
     
     if ([self interactionMode] == SKPresentationMode)
@@ -1111,11 +1111,11 @@
         // this is a revert
         // need to clean up data and actions, and remember settings to restore
         if (pageCount) {
-            dest = [pdfView currentDestination:YES];
+            dest = [pdfView skDestination:YES];
             if (dest.pageIndex >= pageCount && dest.pageIndex != NSNotFound)
                 dest = (SKDestination){pageCount - 1, SKUnspecifiedPoint};
             if (secondaryPdfView) {
-                secondaryDest = [secondaryPdfView currentDestination:YES];
+                secondaryDest = [secondaryPdfView skDestination:YES];
                 if (secondaryDest.pageIndex >= pageCount && 
secondaryDest.pageIndex != NSNotFound)
                     secondaryDest = (SKDestination){pageCount - 1, 
SKUnspecifiedPoint};
             }
@@ -1237,9 +1237,9 @@
         [self showSnapshotsWithSetups:snapshotDicts];
     
     if (unlocked && dest.pageIndex != NSNotFound) {
-        [pdfView goToCurrentDestination:dest];
+        [pdfView goToSKDestination:dest];
         if (secondaryDest.pageIndex != NSNotFound)
-            [secondaryPdfView goToCurrentDestination:secondaryDest];
+            [secondaryPdfView goToSKDestination:secondaryDest];
         [pdfView resetHistory];
     }
     
@@ -2135,7 +2135,7 @@
     
     SKDestination dest = [self destinationFromSetup:savedNormalSetup];
     if (dest.pageIndex != NSNotFound) {
-        [pdfView goToCurrentDestination:dest];
+        [pdfView goToSKDestination:dest];
         [lastViewedPages setCount:0];
         [lastViewedPages addPointer:(void *)dest.pageIndex];
         [pdfView resetHistory];

Modified: trunk/SKMainWindowController_Actions.m
===================================================================
--- trunk/SKMainWindowController_Actions.m      2025-12-23 10:34:21 UTC (rev 
15909)
+++ trunk/SKMainWindowController_Actions.m      2025-12-23 10:38:43 UTC (rev 
15910)
@@ -398,11 +398,11 @@
         return;
     } else if (beforeMarkedPage.pageIndex != NSNotFound) {
         beforeMarkedPage.pageIndex = MIN(beforeMarkedPage.pageIndex, [pdfDoc 
pageCount] - 1);
-        [pdfView goToCurrentDestination:beforeMarkedPage];
+        [pdfView goToSKDestination:beforeMarkedPage];
     } else if (currentPageIndex != markedPage.pageIndex) {
-        beforeMarkedPage = [pdfView currentDestination:NO];
+        beforeMarkedPage = [pdfView skDestination:NO];
         markedPage.pageIndex = MIN(markedPage.pageIndex, [pdfDoc pageCount] - 
1);
-        [pdfView goToCurrentDestination:markedPage];
+        [pdfView goToSKDestination:markedPage];
     }
     if ([self interactionMode] == SKPresentationMode)
         [presentationView setPage:[pdfView currentPage]];
@@ -413,7 +413,7 @@
         [(SKThumbnailItem *)[overviewView itemAtIndexPath:[NSIndexPath 
indexPathForItem:markedPage.pageIndex inSection:0]] setMarked:NO];
         [[(NSTableCellView *)[leftSideController.thumbnailTableView 
viewAtColumn:1 row:markedPage.pageIndex makeIfNecessary:NO] imageView] 
setObjectValue:nil];
     }
-    markedPage = [pdfView currentDestination:NO];
+    markedPage = [pdfView skDestination:NO];
     beforeMarkedPage.pageIndex = NSNotFound;
     [(SKThumbnailItem *)[overviewView itemAtIndexPath:[NSIndexPath 
indexPathForItem:markedPage.pageIndex inSection:0]] setMarked:YES];
     [[(NSTableCellView *)[leftSideController.thumbnailTableView viewAtColumn:1 
row:markedPage.pageIndex makeIfNecessary:NO] imageView] setObjectValue:[NSImage 
markImage]];

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