Change indent width to match other iOS outline view indent widths
This commit is contained in:
parent
2dcde1ab8e
commit
d2482233ab
|
@ -11,7 +11,6 @@ import RSCore
|
|||
|
||||
struct MasterFeedTableViewCellLayout {
|
||||
|
||||
private static let indent = CGFloat(integerLiteral: 14)
|
||||
private static let editingControlIndent = CGFloat(integerLiteral: 40)
|
||||
private static let imageSize = CGSize(width: 20, height: 20)
|
||||
private static let marginLeft = CGFloat(integerLiteral: 8)
|
||||
|
@ -34,7 +33,7 @@ struct MasterFeedTableViewCellLayout {
|
|||
|
||||
var initialIndent = MasterFeedTableViewCellLayout.marginLeft + insets.left
|
||||
if indent {
|
||||
initialIndent += MasterFeedTableViewCellLayout.indent
|
||||
initialIndent += MasterFeedTableViewCellLayout.imageSize.width + MasterFeedTableViewCellLayout.imageMarginRight
|
||||
}
|
||||
if showingEditingControl {
|
||||
initialIndent += MasterFeedTableViewCellLayout.editingControlIndent
|
||||
|
|
|
@ -92,7 +92,7 @@ class MasterFeedTableViewSectionHeader: UITableViewHeaderFooterView {
|
|||
// cell below.
|
||||
unreadCountView.unreadCount = 888
|
||||
|
||||
let layout = MasterFeedTableViewCellLayout(cellWidth: size.width, insets: safeAreaInsets, shouldShowImage: false, label: titleView, unreadCountView: unreadCountView, showingEditingControl: false, indent: true, shouldShowDisclosure: true)
|
||||
let layout = MasterFeedTableViewCellLayout(cellWidth: size.width, insets: safeAreaInsets, shouldShowImage: false, label: titleView, unreadCountView: unreadCountView, showingEditingControl: false, indent: false, shouldShowDisclosure: true)
|
||||
|
||||
return CGSize(width: bounds.width, height: layout.height)
|
||||
|
||||
|
@ -100,7 +100,7 @@ class MasterFeedTableViewSectionHeader: UITableViewHeaderFooterView {
|
|||
|
||||
override func layoutSubviews() {
|
||||
super.layoutSubviews()
|
||||
let layout = MasterFeedTableViewCellLayout(cellWidth: bounds.size.width, insets: safeAreaInsets, shouldShowImage: false, label: titleView, unreadCountView: unreadCountView, showingEditingControl: false, indent: true, shouldShowDisclosure: true)
|
||||
let layout = MasterFeedTableViewCellLayout(cellWidth: bounds.size.width, insets: safeAreaInsets, shouldShowImage: false, label: titleView, unreadCountView: unreadCountView, showingEditingControl: false, indent: false, shouldShowDisclosure: true)
|
||||
layoutWith(layout)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue