Skip to content

Commit

Permalink
Fix Evolution cells layout bug.
Browse files Browse the repository at this point in the history
  • Loading branch information
Frog-Frog committed Feb 18, 2021
1 parent 3ee216c commit 6e62b8b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ extension EvolutionChainViewController: EvolutionChainView {
self.pageControl.numberOfPages = self.evolutionChains.count
self.actionSheetHeightConstraint.constant = model.chainType.actionSheetHeight
self.collectionView.reloadData {
// If we do not call the method layoutIfNeeded() here, the contents of visibleCells will be empty.
self.collectionView.layoutIfNeeded()
self.setCellActive()
}
self.executeShowAnimation()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<rect key="frame" x="0.0" y="0.0" width="255" height="206"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" distribution="fillEqually" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="F40-vo-6O0">
<stackView opaque="NO" alpha="0.29999999999999999" contentMode="scaleToFill" axis="vertical" distribution="fillEqually" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="F40-vo-6O0">
<rect key="frame" x="4" y="0.0" width="247" height="206"/>
<color key="backgroundColor" name="Background"/>
<constraints>
Expand Down

0 comments on commit 6e62b8b

Please sign in to comment.