Revision: 13302 http://sourceforge.net/p/skim-app/code/13302 Author: hofman Date: 2023-02-25 15:55:54 +0000 (Sat, 25 Feb 2023) Log Message: ----------- remove popup from skim note after adding to a page
Modified Paths: -------------- trunk/SKNPDFAnnotationNote_SKExtensions.m trunk/SKPDFPage.m Modified: trunk/SKNPDFAnnotationNote_SKExtensions.m =================================================================== --- trunk/SKNPDFAnnotationNote_SKExtensions.m 2023-02-25 10:42:28 UTC (rev 13301) +++ trunk/SKNPDFAnnotationNote_SKExtensions.m 2023-02-25 15:55:54 UTC (rev 13302) @@ -102,8 +102,6 @@ // override these Leopard methods to avoid showing the standard tool tips over our own - (NSString *)toolTip { return @""; } -- (PDFAnnotationPopup *)popup { return nil; } - - (BOOL)hasNoteText { return YES; } - (SKNoteText *)noteText { Modified: trunk/SKPDFPage.m =================================================================== --- trunk/SKPDFPage.m 2023-02-25 10:42:28 UTC (rev 13301) +++ trunk/SKPDFPage.m 2023-02-25 15:55:54 UTC (rev 13302) @@ -98,6 +98,11 @@ if (NSContainsRect(foregroundBox, [annotation bounds]) == NO) foregroundBox = NSZeroRect; [super addAnnotation:annotation]; + PDFAnnotation *popup = [annotation popup]; + if (popup && [annotation isSkimNote]) { + [super removeAnnotation:popup]; + [annotation setPopup:nil]; + } } - (void)removeAnnotation:(PDFAnnotation *)annotation { 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