Skip to content

Commit

Permalink
Merge pull request #293 from nulab/master
Browse files Browse the repository at this point in the history
Fix broken layout on iPhone 12 and iPhone 12 Pro
  • Loading branch information
tilltue authored Nov 1, 2020
2 parents 35d1e28 + b797dab commit b055857
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion TLPhotoPicker/Classes/TLPhotosPickerViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ extension TLPhotosPickerViewController {
return
}
let count = CGFloat(self.configure.numberOfColumn)
let width = (self.view.frame.size.width-(5*(count-1)))/count
let width = floor((self.view.frame.size.width-(5*(count-1)))/count)
self.thumbnailSize = CGSize(width: width, height: width)
layout.itemSize = self.thumbnailSize
self.collectionView.collectionViewLayout = layout
Expand Down

0 comments on commit b055857

Please sign in to comment.