Use the new macro from Swift compiler and SDK to mark the UIImage/UIImageView subclass matching what they designed to be
UIImage subclass should be thread-safe UIImageView subclass should be on MainActor only
This commit is contained in:
parent
be0bcd7823
commit
ed17b02a5f
|
@ -68,6 +68,7 @@
|
||||||
/**
|
/**
|
||||||
The image class which supports animating on `SDAnimatedImageView`. You can also use it on normal UIImageView/NSImageView.
|
The image class which supports animating on `SDAnimatedImageView`. You can also use it on normal UIImageView/NSImageView.
|
||||||
*/
|
*/
|
||||||
|
NS_SWIFT_NONISOLATED
|
||||||
@interface SDAnimatedImage : UIImage <SDAnimatedImage>
|
@interface SDAnimatedImage : UIImage <SDAnimatedImage>
|
||||||
|
|
||||||
// This class override these methods from UIImage(NSImage), and it supports NSSecureCoding.
|
// This class override these methods from UIImage(NSImage), and it supports NSSecureCoding.
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
For UIKit: use `-startAnimating`, `-stopAnimating` to control animating. `isAnimating` to check animation state.
|
For UIKit: use `-startAnimating`, `-stopAnimating` to control animating. `isAnimating` to check animation state.
|
||||||
For AppKit: use `-setAnimates:` to control animating, `animates` to check animation state. This view is layer-backed.
|
For AppKit: use `-setAnimates:` to control animating, `animates` to check animation state. This view is layer-backed.
|
||||||
*/
|
*/
|
||||||
|
NS_SWIFT_UI_ACTOR
|
||||||
@interface SDAnimatedImageView : UIImageView
|
@interface SDAnimatedImageView : UIImageView
|
||||||
/**
|
/**
|
||||||
The internal animation player.
|
The internal animation player.
|
||||||
|
|
Loading…
Reference in New Issue