Skip to content

Commit 2f447b2

Browse files
committed
#2 Fixed reloadContentFromStackView() called even at first layout
1 parent 66b279f commit 2f447b2

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

Sources/ScrollStackController/ScrollStack.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -615,6 +615,7 @@ open class ScrollStack: UIScrollView, UIScrollViewDelegate {
615615

616616
rows.forEach {
617617
$0.askForCutomizedSizeOfContentView(animated: animated)
618+
($0.controller as? ScrollStackContainableController)?.reloadContentFromStackView(stackView: self, row: $0, animated: animated)
618619
}
619620

620621
UIView.execute(animated: animated, {

Sources/ScrollStackController/ScrollStackRow.swift

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,6 @@ open class ScrollStackRow: UIView, UIGestureRecognizerDelegate {
267267
case .fitLayoutForAxis:
268268
setupRowSizeToFitLayout()
269269
}
270-
271-
customizableController.reloadContentFromStackView(stackView: stackView!, row: self, animated: animated)
272270
}
273271

274272
private func setupRowToFixedValue(_ value: CGFloat) {

0 commit comments

Comments
 (0)