revised due to registry limitations
This commit is contained in:
parent
94a8ac405e
commit
2e41876006
@ -74,18 +74,6 @@ open class BarsIndicatorView: CarouselIndicator {
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
// MARK: - Initializers
|
||||
//--------------------------------------------------
|
||||
|
||||
public init() {
|
||||
super.init(frame: .zero)
|
||||
}
|
||||
|
||||
public required init?(coder: NSCoder) {
|
||||
fatalError("init(coder:) has not been implemented")
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
// MARK: - Setup
|
||||
//--------------------------------------------------
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
import Foundation
|
||||
|
||||
|
||||
open class CarouselIndicatorModel: CarouselPagingModelProtocol {
|
||||
open class CarouselIndicatorModel: CarouselPagingModelProtocol, MoleculeModelProtocol {
|
||||
//--------------------------------------------------
|
||||
// MARK: - Properties
|
||||
//--------------------------------------------------
|
||||
|
||||
@ -60,22 +60,6 @@ open class NumericIndicatorView: CarouselIndicator {
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
// MARK: - Initializers
|
||||
//--------------------------------------------------
|
||||
|
||||
public override init(frame: CGRect) {
|
||||
super.init(frame: .zero)
|
||||
}
|
||||
|
||||
public convenience init() {
|
||||
self.init(frame: .zero)
|
||||
}
|
||||
|
||||
public required init?(coder: NSCoder) {
|
||||
fatalError("init(coder:) has not been implemented")
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
// MARK: - Lifecycle
|
||||
//--------------------------------------------------
|
||||
|
||||
@ -125,7 +125,7 @@ open class Carousel: View {
|
||||
collectionViewHeight?.isActive = true
|
||||
}
|
||||
|
||||
setupPagingMolecule(carouselModel.pagingMolecule, delegateObject: delegateObject)
|
||||
setupPagingMolecule((carouselModel.pagingMolecule as! (CarouselPagingModelProtocol & MoleculeModelProtocol)), delegateObject: delegateObject)
|
||||
collectionView.reloadData()
|
||||
}
|
||||
|
||||
@ -174,7 +174,7 @@ open class Carousel: View {
|
||||
}
|
||||
|
||||
/// Sets up the paging molecule
|
||||
open func setupPagingMolecule(_ molecule: CarouselPagingModelProtocol?, delegateObject: MVMCoreUIDelegateObject?) {
|
||||
open func setupPagingMolecule(_ molecule: (MoleculeModelProtocol & CarouselPagingModelProtocol)?, delegateObject: MVMCoreUIDelegateObject?) {
|
||||
|
||||
var pagingView: (UIView & CarouselPageControlProtocol)? = nil
|
||||
|
||||
|
||||
@ -27,7 +27,7 @@ import UIKit
|
||||
public var height: Float?
|
||||
public var itemWidthPercent: Float?
|
||||
public var itemAlignment: UICollectionView.ScrollPosition?
|
||||
public var pagingMolecule: CarouselPagingModelProtocol?
|
||||
public var pagingMolecule: MoleculeModelProtocol?
|
||||
|
||||
//--------------------------------------------------
|
||||
// MARK: - Initializer
|
||||
|
||||
@ -9,6 +9,6 @@
|
||||
import Foundation
|
||||
|
||||
|
||||
public protocol CarouselPagingModelProtocol: MoleculeModelProtocol {
|
||||
public protocol CarouselPagingModelProtocol {
|
||||
var position: Float? { get }
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user