Revision: 14678 http://sourceforge.net/p/skim-app/code/14678 Author: hofman Date: 2024-11-12 10:33:34 +0000 (Tue, 12 Nov 2024) Log Message: ----------- remove unused class for recent document info
Modified Paths: -------------- trunk/Skim.xcodeproj/project.pbxproj Removed Paths: ------------- trunk/SKRecentDocumentInfo.h trunk/SKRecentDocumentInfo.m Deleted: trunk/SKRecentDocumentInfo.h =================================================================== --- trunk/SKRecentDocumentInfo.h 2024-11-12 10:32:34 UTC (rev 14677) +++ trunk/SKRecentDocumentInfo.h 2024-11-12 10:33:34 UTC (rev 14678) @@ -1,61 +0,0 @@ -// -// SKRecentDocumentInfo.h -// Skim -// -// Created by Christiaan Hofman on 23/11/2020. -/* -This software is Copyright (c) 2020 -Adam Maxwell. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - -- Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - -- Redistributions in binary form must reproduce the above copyright -notice, this list of conditions and the following disclaimer in -the documentation and/or other materials provided with the -distribution. - -- Neither the name of Adam Maxwell nor the names of any -contributors may be used to endorse or promote products derived -from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -*/ - -#import <Cocoa/Cocoa.h> - -NS_ASSUME_NONNULL_BEGIN - -@class SKAlias; - -@interface SKRecentDocumentInfo : NSObject { - SKAlias *alias; - NSUInteger pageIndex; - NSArray<NSDictionary<NSString *, id> *> *snapshots; -} - -- (instancetype)initWithProperties:(NSDictionary<NSString *, id> *)properties; -- (instancetype)initWithURL:(NSURL *)fileURL pageIndex:(NSUInteger)aPageIndex snapshots:(NSArray<NSDictionary<NSString *, id> *> *)aSnapshots; - -@property (nonatomic, nullable, readonly) NSURL *fileURL; -@property (nonatomic, readonly) NSUInteger pageIndex; -@property (nonatomic, nullable, readonly) NSArray<NSDictionary<NSString *, id> *> *snapshots; -@property (nonatomic, readonly) NSDictionary<NSString *, id> *properties; - -@end - -NS_ASSUME_NONNULL_END Deleted: trunk/SKRecentDocumentInfo.m =================================================================== --- trunk/SKRecentDocumentInfo.m 2024-11-12 10:32:34 UTC (rev 14677) +++ trunk/SKRecentDocumentInfo.m 2024-11-12 10:33:34 UTC (rev 14678) @@ -1,95 +0,0 @@ -// -// SKRecentDocumentInfo.m -// Skim -// -// Created by Christiaan Hofman on 23/11/2020. -/* -This software is Copyright (c) 2020 -Adam Maxwell. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - -- Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - -- Redistributions in binary form must reproduce the above copyright -notice, this list of conditions and the following disclaimer in -the documentation and/or other materials provided with the -distribution. - -- Neither the name of Adam Maxwell nor the names of any -contributors may be used to endorse or promote products derived -from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -*/ - -#import "SKRecentDocumentInfo.h" -#import "SKAlias.h" - -#define PAGEINDEX_KEY @"pageIndex" -#define ALIASDATA_KEY @"_BDAlias" -#define BOOKMARK_KEY @"bookmark" -#define SNAPSHOTS_KEY @"snapshots" - -@implementation SKRecentDocumentInfo - -@synthesize pageIndex, snapshots; -@dynamic fileURL, properties; - -- (instancetype)initWithProperties:(NSDictionary *)properties { - self = [super init]; - if (self) { - NSNumber *pageNumber = [properties objectForKey:PAGEINDEX_KEY]; - pageIndex = pageNumber ? [pageNumber unsignedIntegerValue] : NSNotFound; - snapshots = [[properties objectForKey:SNAPSHOTS_KEY] copy]; - NSData *data; - if ((data = [properties objectForKey:ALIASDATA_KEY])) - alias = [[SKAlias alloc] initWithAliasData:data]; - else if ((data = [properties objectForKey:BOOKMARK_KEY])) - alias = [[SKAlias alloc] initWithBookmarkData:data]; - } - return self; -} - -- (instancetype)initWithURL:(NSURL *)fileURL pageIndex:(NSUInteger)aPageIndex snapshots:(NSArray *)aSnapshots { - self = [super init]; - if (self) { - alias = [[SKAlias alloc] initWithURL:fileURL]; - if (alias) { - pageIndex = aPageIndex; - snapshots = [aSnapshots count] ? [aSnapshots copy] : nil; - } else { - self = nil; - } - } - return self; -} - -- (NSURL *)fileURL { - return [alias fileURLNoUI]; -} - -- (NSDictionary *)properties { - NSData *data = [alias data]; - NSString *dataKey = [alias isBookmark] ? BOOKMARK_KEY : ALIASDATA_KEY; - return [NSDictionary dictionaryWithObjectsAndKeys: - [NSNumber numberWithUnsignedInteger:pageIndex], PAGEINDEX_KEY, - data, dataKey, - snapshots, SNAPSHOTS_KEY, - nil]; -} - -@end Modified: trunk/Skim.xcodeproj/project.pbxproj =================================================================== --- trunk/Skim.xcodeproj/project.pbxproj 2024-11-12 10:32:34 UTC (rev 14677) +++ trunk/Skim.xcodeproj/project.pbxproj 2024-11-12 10:33:34 UTC (rev 14678) @@ -74,7 +74,6 @@ CE19446710627483007E8770 /* ProgressSheet.xib in Resources */ = {isa = PBXBuildFile; fileRef = CE19446010627483007E8770 /* ProgressSheet.xib */; }; CE19446910627483007E8770 /* SnapshotWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = CE19446210627483007E8770 /* SnapshotWindow.xib */; }; CE19641516E811D40027E2CF /* SKSnapshotWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = CE19641416E811D40027E2CF /* SKSnapshotWindow.m */; }; - CE1991E0256C70CD00FC4E25 /* SKRecentDocumentInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = CE1991DF256C70CD00FC4E25 /* SKRecentDocumentInfo.m */; }; CE199DFD0D957A16009B2055 /* SKAnnotationTypeImageCell.m in Sources */ = {isa = PBXBuildFile; fileRef = CE199DFC0D957A16009B2055 /* SKAnnotationTypeImageCell.m */; }; CE19E7A9275B7BC1007EBD8B /* SKDisplayPrefs.m in Sources */ = {isa = PBXBuildFile; fileRef = CE19E7A8275B7BC1007EBD8B /* SKDisplayPrefs.m */; }; CE1ADEBF0C4C341100071840 /* SKTransitionController.m in Sources */ = {isa = PBXBuildFile; fileRef = CE1ADEBE0C4C341100071840 /* SKTransitionController.m */; }; @@ -831,8 +830,6 @@ CE19446210627483007E8770 /* SnapshotWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = SnapshotWindow.xib; sourceTree = "<group>"; }; CE19641316E811D40027E2CF /* SKSnapshotWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKSnapshotWindow.h; sourceTree = "<group>"; }; CE19641416E811D40027E2CF /* SKSnapshotWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKSnapshotWindow.m; sourceTree = "<group>"; }; - CE1991DE256C70CD00FC4E25 /* SKRecentDocumentInfo.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SKRecentDocumentInfo.h; sourceTree = "<group>"; }; - CE1991DF256C70CD00FC4E25 /* SKRecentDocumentInfo.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SKRecentDocumentInfo.m; sourceTree = "<group>"; }; CE199DFB0D957A16009B2055 /* SKAnnotationTypeImageCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKAnnotationTypeImageCell.h; sourceTree = "<group>"; }; CE199DFC0D957A16009B2055 /* SKAnnotationTypeImageCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKAnnotationTypeImageCell.m; sourceTree = "<group>"; }; CE19E7A7275B7BC1007EBD8B /* SKDisplayPrefs.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SKDisplayPrefs.h; sourceTree = "<group>"; }; @@ -1972,8 +1969,6 @@ CE3366DE0E28BCFA005F99E6 /* SKPDFSyncRecord.m */, CE4294A10BBD29120016FDC2 /* SKReadingBar.h */, CE4294A20BBD29120016FDC2 /* SKReadingBar.m */, - CE1991DE256C70CD00FC4E25 /* SKRecentDocumentInfo.h */, - CE1991DF256C70CD00FC4E25 /* SKRecentDocumentInfo.m */, CE2E9A572C14D2F300044B01 /* SKSnapshotConfiguration.h */, CE2E9A582C14D2F300044B01 /* SKSnapshotConfiguration.m */, CE26175D16CCFC4900BDCE7C /* SKSyncDot.h */, @@ -2907,7 +2902,6 @@ CEAE1CA0287C7C39003A77DB /* SKGroupView.m in Sources */, CEDB6A7A228F596000F93C87 /* SKColorPicker.m in Sources */, CE209FAA0C9D38C6007C72F9 /* SKProgressController.m in Sources */, - CE1991E0256C70CD00FC4E25 /* SKRecentDocumentInfo.m in Sources */, CE20B1950C9F23CC007C72F9 /* NSView_SKExtensions.m in Sources */, CE7A3A402269CC5E00F1B89B /* SKProgressTableCellView.m in Sources */, CEAE1C480CA1877F00849B0F /* SKSecondaryPDFView.m in Sources */, 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