FrameDataSource
@objc(PESDKFrameDataSource) open class FrameDataSource: NSObject
A frame data source provides the frames that should be displayed in the frame tool.
-
The collection view of this data source.
Declaration
Swift
open let collectionView: UICollectionView
-
The currently used image aspect ratio.
Declaration
Swift
open var ratio = CGFloat(1)
-
Get all frames matching the set ratio and tolerance.
Declaration
Swift
open var matchingFrames: [Frame]?
-
A closure that is called to modify the ‘No Frame’ cell.
Declaration
Swift
open var noFrameCellConfigurationClosure: ((IconCaptionCollectionViewCell) -> Void)?
-
A closure that is called to modify the cell for a given frame.
Declaration
Swift
open var frameCellConfigurationClosure: ((IconBorderedCollectionViewCell, Frame) -> Void)?
-
Creates a new frame data source for the given collection view.
Declaration
Swift
public init(collectionView: UICollectionView)
Parameters
collectionView
The collection view of this data source.