Revision: 29743
          http://sourceforge.net/p/bibdesk/svn/29743
Author:   hofman
Date:     2025-10-20 14:34:30 +0000 (Mon, 20 Oct 2025)
Log Message:
-----------
declare designated initializers for fileview icon classes

Modified Paths:
--------------
    trunk/bibdesk_vendorsrc/amaxwell/FileView/FVBaseIcon.h
    trunk/bibdesk_vendorsrc/amaxwell/FileView/FVFinderIcon.m
    trunk/bibdesk_vendorsrc/amaxwell/FileView/FVMIMEIcon.h
    trunk/bibdesk_vendorsrc/amaxwell/FileView/FVTextIcon.h
    trunk/bibdesk_vendorsrc/amaxwell/FileView/FVWebViewIcon.h

Modified: trunk/bibdesk_vendorsrc/amaxwell/FileView/FVBaseIcon.h
===================================================================
--- trunk/bibdesk_vendorsrc/amaxwell/FileView/FVBaseIcon.h      2025-10-20 
09:31:43 UTC (rev 29742)
+++ trunk/bibdesk_vendorsrc/amaxwell/FileView/FVBaseIcon.h      2025-10-20 
14:34:30 UTC (rev 29743)
@@ -61,8 +61,10 @@
 /** Designated initializer.
  @param aURL Any NSURL instance.
  @param drawsLinkBadge A BOOL. */
-- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge;
+- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge 
NS_DESIGNATED_INITIALIZER;
 
+- (id)init NS_UNAVAILABLE;
+
 /** @brief Addition to NSLocking.
  
  Returns immediately without blocking.

Modified: trunk/bibdesk_vendorsrc/amaxwell/FileView/FVFinderIcon.m
===================================================================
--- trunk/bibdesk_vendorsrc/amaxwell/FileView/FVFinderIcon.m    2025-10-20 
09:31:43 UTC (rev 29742)
+++ trunk/bibdesk_vendorsrc/amaxwell/FileView/FVFinderIcon.m    2025-10-20 
14:34:30 UTC (rev 29743)
@@ -44,7 +44,8 @@
     NSImage        *_icon;
     BOOL            _drawsLinkBadge;
 }
-- (id)initWithIcon:(NSImage *)icon drawsLinkBadge:(BOOL)drawsLinkBadge;
+- (id)initWithIcon:(NSImage *)icon drawsLinkBadge:(BOOL)drawsLinkBadge 
NS_DESIGNATED_INITIALIZER;
+- (id)init NS_UNAVAILABLE;
 @end
 
 // Apple seems to use JPEG2000 storage for icons, and decompressing them is a 
serious performance hit on the main thread (when scrolling).  Hence, we'll 
create the images here and burn some memory to handle the common cases.  Custom 
icons still get their own instance and are drawn as needed with Icon Services.
@@ -54,7 +55,8 @@
     CGImageRef _thumbnail;
     CGImageRef _fullImage;
 }
-- (id)initWithType:(NSString *)type badgeType:(NSString *)badgeType;
+- (id)initWithType:(NSString *)type badgeType:(NSString *)badgeType 
NS_DESIGNATED_INITIALIZER;
+- (id)init NS_UNAVAILABLE;
 @end
 
 @implementation FVFinderIcon
@@ -210,7 +212,7 @@
 
 - (id)initWithIcon:(NSImage *)icon drawsLinkBadge:(BOOL)drawsLinkBadge;
 {
-    self = [self init];
+    self = [super init];
     if (self) {
         _drawsLinkBadge = drawsLinkBadge;
         _icon = icon;

Modified: trunk/bibdesk_vendorsrc/amaxwell/FileView/FVMIMEIcon.h
===================================================================
--- trunk/bibdesk_vendorsrc/amaxwell/FileView/FVMIMEIcon.h      2025-10-20 
09:31:43 UTC (rev 29742)
+++ trunk/bibdesk_vendorsrc/amaxwell/FileView/FVMIMEIcon.h      2025-10-20 
14:34:30 UTC (rev 29743)
@@ -53,6 +53,8 @@
 + (id)newIconWithType:(NSString *)type;
 
 // you probably want to use +newWithMIMEType:
-- (id)initWithType:(NSString *)type;
+- (id)initWithType:(NSString *)type NS_DESIGNATED_INITIALIZER;
 
+- (id)init NS_UNAVAILABLE;
+
 @end

Modified: trunk/bibdesk_vendorsrc/amaxwell/FileView/FVTextIcon.h
===================================================================
--- trunk/bibdesk_vendorsrc/amaxwell/FileView/FVTextIcon.h      2025-10-20 
09:31:43 UTC (rev 29742)
+++ trunk/bibdesk_vendorsrc/amaxwell/FileView/FVTextIcon.h      2025-10-20 
14:34:30 UTC (rev 29743)
@@ -45,6 +45,6 @@
     BOOL            _isPlainText;
 }
 
-- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge 
isPlainText:(BOOL)isPlainText;
+- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge 
isPlainText:(BOOL)isPlainText NS_DESIGNATED_INITIALIZER;
 
 @end

Modified: trunk/bibdesk_vendorsrc/amaxwell/FileView/FVWebViewIcon.h
===================================================================
--- trunk/bibdesk_vendorsrc/amaxwell/FileView/FVWebViewIcon.h   2025-10-20 
09:31:43 UTC (rev 29742)
+++ trunk/bibdesk_vendorsrc/amaxwell/FileView/FVWebViewIcon.h   2025-10-20 
14:34:30 UTC (rev 29743)
@@ -58,6 +58,8 @@
 
 + (BOOL)canInitWithURL:(NSURL *)aURL withType:(NSString *)type;
 
-- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge;
+- (id)initWithURL:(NSURL *)aURL drawsLinkBadge:(BOOL)drawsLinkBadge 
NS_DESIGNATED_INITIALIZER;
 
+- (id)init NS_UNAVAILABLE;
+
 @end

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



_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to