RSDAnimatedImageThemeElementObject
public struct RSDAnimatedImageThemeElementObject : RSDAnimatedImageThemeElement, RSDDecodableBundleInfo, Codable
RSDAnimatedImageThemeElementObject
is a Codable
concrete implementation of RSDAnimatedImageThemeElement
.
-
The list of image names for the images to include in this animation.
Declaration
Swift
public let imageNames: [String]
-
The animation duration for the image animation.
Declaration
Swift
public let animationDuration: TimeInterval
-
The preferred placement of the image.
Declaration
Swift
public let placementType: RSDImagePlacementType?
-
The bundle identifier for the image resource bundle.
Declaration
Swift
public let bundleIdentifier: String?
-
The image size.
Declaration
Swift
public var size: CGSize?
-
The unique identifier for the image
Declaration
Swift
public var identifier: String
-
Default initializer.
Declaration
Swift
public init(imageNames: [String], animationDuration: TimeInterval, bundleIdentifier: String? = nil, placementType: RSDImagePlacementType? = nil, size: CGSize? = nil)
Parameters
imageNames
The names of the images.
bundleIdentifier
The bundle identifier for the image resource bundle. Default =
nil
.animationDuration
The animation duration.
placementType
The preferred placement of the image. Default =
nil
.size
The image size. Default =
nil
. -
Available for watchOS.
The animated images to display.
-
Available for iOS and tvOS.
The animated images to display.
Declaration
Swift
public func images(compatibleWith traitCollection: UITraitCollection? = nil) -> [UIImage]
Parameters
traitCollection
The trait collection.
Return Value
The images for this step.
-
A method for fetching the image.
Declaration
Swift
public func fetchImage(for size: CGSize, callback: @escaping ((UIImage?) -> Void))
Parameters
size
The size of the image to return.
callback
The callback with the image, run on the main thread.