Revision: 12881 http://sourceforge.net/p/skim-app/code/12881 Author: hofman Date: 2022-05-04 15:08:44 +0000 (Wed, 04 May 2022) Log Message: ----------- remove unused class files
Modified Paths: -------------- trunk/Skim.xcodeproj/project.pbxproj Removed Paths: ------------- trunk/SKReflectionView.h trunk/SKReflectionView.m Deleted: trunk/SKReflectionView.h =================================================================== --- trunk/SKReflectionView.h 2022-05-04 15:05:49 UTC (rev 12880) +++ trunk/SKReflectionView.h 2022-05-04 15:08:44 UTC (rev 12881) @@ -1,51 +0,0 @@ -// -// SKReflectionView.h -// Skim -// -// Created by Christiaan Hofman on 14/09/2020. -/* -This software is Copyright (c) 2020-2022 -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> - - -@interface SKReflectionView : NSView { - NSScrollView *reflectedScrollView; - BOOL wantsFilters; -} - -@property (nonatomic, retain) NSScrollView *reflectedScrollView; -@property (nonatomic) BOOL wantsFilters; - -@end - Deleted: trunk/SKReflectionView.m =================================================================== --- trunk/SKReflectionView.m 2022-05-04 15:05:49 UTC (rev 12880) +++ trunk/SKReflectionView.m 2022-05-04 15:08:44 UTC (rev 12881) @@ -1,120 +0,0 @@ -// -// SKReflectionView.m -// Skim -// -// Created by Christiaan Hofman on 14/09/2020. -/* -This software is Copyright (c) 2020-2022 -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 "SKReflectionView.h" -#import "NSView_SKExtensions.h" -#import "NSGraphics_SKExtensions.h" -#import "NSUserDefaultsController_SKExtensions.h" -#import "SKStringConstants.h" - -static char SKReflectionViewDefaultsObservationContext; - -@implementation SKReflectionView - -@synthesize reflectedScrollView,wantsFilters; - -- (void)dealloc { - if (wantsFilters) { - @try { [[NSUserDefaultsController sharedUserDefaultsController] removeObserver:self forKeys:[NSArray arrayWithObjects:SKInvertColorsInDarkModeKey, SKSepiaToneKey, nil] context:&SKReflectionViewDefaultsObservationContext]; } - @catch (id e) {} - } - [[NSNotificationCenter defaultCenter] removeObserver:self]; - SKDESTROY(reflectedScrollView); - [super dealloc]; -} - -- (void)setWantsFilters:(BOOL)flag { - if (flag != wantsFilters) { - wantsFilters = flag; - if (wantsFilters) { - [self setContentFilters:SKColorEffectFilters()]; - [[NSUserDefaultsController sharedUserDefaultsController] addObserver:self forKeys:[NSArray arrayWithObjects:SKInvertColorsInDarkModeKey, SKSepiaToneKey, nil] context:&SKReflectionViewDefaultsObservationContext]; - } else { - [self setContentFilters:[NSArray array]]; - [[NSUserDefaultsController sharedUserDefaultsController] removeObserver:self forKeys:[NSArray arrayWithObjects:SKInvertColorsInDarkModeKey, SKSepiaToneKey, nil] context:&SKReflectionViewDefaultsObservationContext]; - } - } -} - -- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context { - if (context == &SKReflectionViewDefaultsObservationContext) - [self setContentFilters:SKColorEffectFilters()]; - else - [super observeValueForKeyPath:keyPath ofObject:object change:change context:context]; -} - -- (void)viewDidChangeEffectiveAppearance { -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wpartial-availability" - [super viewDidChangeEffectiveAppearance]; -#pragma clang diagnostic pop - if (wantsFilters) - [self setContentFilters:SKColorEffectFilters()]; -} - -- (void)drawRect:(NSRect)dirtyRect { - if ([reflectedScrollView window] == nil || [reflectedScrollView window] != [self window]) - return; - NSView *view = [[self reflectedScrollView] documentView]; - if (view == nil) - return; - NSRect rect = NSIntersectionRect([self convertRect:[self bounds] toView:view], [view bounds]); - if (NSIsEmptyRect(rect)) - return; - NSBitmapImageRep *imageRep = [view bitmapImageRepCachingDisplayInRect:rect]; - rect = [self convertRect:rect fromView:view]; - [imageRep drawInRect:rect fromRect:NSZeroRect operation:NSCompositeSourceOver fraction:1.0 respectFlipped:YES hints:[NSDictionary dictionaryWithObjectsAndKeys:[NSNumber numberWithInteger:NSImageInterpolationNone], NSImageHintInterpolation, nil]]; -} - -- (void)reflectedSscrollBoundsChanged:(NSNotification *)notification { - [self setNeedsDisplay:YES]; -} - -- (void)setReflectedScrollView:(NSScrollView *)view { - if (view != reflectedScrollView) { - if (reflectedScrollView) - [[NSNotificationCenter defaultCenter] removeObserver:self name:NSViewBoundsDidChangeNotification object:[reflectedScrollView contentView]]; - [reflectedScrollView release]; - reflectedScrollView = [view retain]; - if (reflectedScrollView) - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(reflectedSscrollBoundsChanged:) name:NSViewBoundsDidChangeNotification object:[reflectedScrollView contentView]]; - [self setNeedsDisplay:YES]; - } -} - -@end Modified: trunk/Skim.xcodeproj/project.pbxproj =================================================================== --- trunk/Skim.xcodeproj/project.pbxproj 2022-05-04 15:05:49 UTC (rev 12880) +++ trunk/Skim.xcodeproj/project.pbxproj 2022-05-04 15:08:44 UTC (rev 12881) @@ -201,7 +201,6 @@ CE820AEF21A04EB100AD34BE /* NSWindow_SKExtensions.m in Sources */ = {isa = PBXBuildFile; fileRef = CE820AEE21A04EB100AD34BE /* NSWindow_SKExtensions.m */; }; CE8388BC115BC61F00DB1AD7 /* SKNoteTypeSheetController.m in Sources */ = {isa = PBXBuildFile; fileRef = CE8388BB115BC61F00DB1AD7 /* SKNoteTypeSheetController.m */; }; CE85D73F2280814B0022C560 /* SKMainTouchBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = CE85D73E2280814B0022C560 /* SKMainTouchBarController.m */; }; - CE863881250FDB9A004C7526 /* SKReflectionView.m in Sources */ = {isa = PBXBuildFile; fileRef = CE863880250FDB9A004C7526 /* SKReflectionView.m */; }; CE8978CE0CBFC70B00EA2D98 /* SKTemplateTag.m in Sources */ = {isa = PBXBuildFile; fileRef = CE8978CC0CBFC70B00EA2D98 /* SKTemplateTag.m */; }; CE898F060C843A8B008A0856 /* PDFDDocument.icns in Resources */ = {isa = PBXBuildFile; fileRef = CE898F050C843A8B008A0856 /* PDFDDocument.icns */; }; CE8B46E90C29CA00005CE7F1 /* SKLineInspector.m in Sources */ = {isa = PBXBuildFile; fileRef = CE8B46E70C29CA00005CE7F1 /* SKLineInspector.m */; }; @@ -1005,8 +1004,6 @@ CE85D73D2280814B0022C560 /* SKMainTouchBarController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SKMainTouchBarController.h; sourceTree = "<group>"; }; CE85D73E2280814B0022C560 /* SKMainTouchBarController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SKMainTouchBarController.m; sourceTree = "<group>"; }; CE85D7502280A4F10022C560 /* NSTouchBar_SKForwardDeclarations.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = NSTouchBar_SKForwardDeclarations.h; sourceTree = "<group>"; }; - CE86387F250FDB9A004C7526 /* SKReflectionView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SKReflectionView.h; sourceTree = "<group>"; }; - CE863880250FDB9A004C7526 /* SKReflectionView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SKReflectionView.m; sourceTree = "<group>"; }; CE8978CB0CBFC70B00EA2D98 /* SKTemplateTag.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKTemplateTag.h; sourceTree = "<group>"; }; CE8978CC0CBFC70B00EA2D98 /* SKTemplateTag.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKTemplateTag.m; sourceTree = "<group>"; }; CE898F050C843A8B008A0856 /* PDFDDocument.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = PDFDDocument.icns; sourceTree = "<group>"; }; @@ -1807,8 +1804,6 @@ CE7611630EA49D1400301E45 /* SKPrintableView.m */, CE7A3A3E2269CC5E00F1B89B /* SKProgressTableCellView.h */, CE7A3A3F2269CC5E00F1B89B /* SKProgressTableCellView.m */, - CE86387F250FDB9A004C7526 /* SKReflectionView.h */, - CE863880250FDB9A004C7526 /* SKReflectionView.m */, CEEB32811AC30ECA00BDB4E8 /* SKScroller.h */, CEEB32821AC30ECA00BDB4E8 /* SKScroller.m */, CED76EFF1A1825DE00D1ACA4 /* SKScrollView.h */, @@ -2789,7 +2784,6 @@ CE121AC81180644A00951425 /* SKScriptMenu.m in Sources */, CEFDEA9111F6FF8300D6FEBA /* NSScreen_SKExtensions.m in Sources */, CE1C77B6123FB41E00C73F1A /* SKNoteTextView.m in Sources */, - CE863881250FDB9A004C7526 /* SKReflectionView.m in Sources */, CE94D17B125535DE0053A520 /* synctex_parser_utils.m in Sources */, CE1D798F129FE44E00EA3AF0 /* NSScriptCommand_SKExtensions.m in Sources */, CE4E1E9A12BCFF5A005227ED /* HIDRemote.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