mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-19 08:03:50 +02:00
Remove empty section spaces
This commit is contained in:
@@ -36,6 +36,8 @@ final class CallTransferSelectContactViewController: UIViewController {
|
||||
|
||||
private enum Constants {
|
||||
static let maxNumberOfRecentContacts: UInt = 10
|
||||
static let sectionHeaderHeightDefault: CGFloat = 30.0
|
||||
static let sectionHeaderHeightHidden: CGFloat = 0.01
|
||||
}
|
||||
|
||||
private var session: MXSession!
|
||||
@@ -237,6 +239,20 @@ extension CallTransferSelectContactViewController: UITableViewDelegate {
|
||||
return sections[section].header
|
||||
}
|
||||
|
||||
func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
|
||||
if sections[section].header != nil {
|
||||
return Constants.sectionHeaderHeightDefault
|
||||
}
|
||||
return Constants.sectionHeaderHeightHidden
|
||||
}
|
||||
|
||||
func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
|
||||
if sections[section].header != nil {
|
||||
return Constants.sectionHeaderHeightDefault
|
||||
}
|
||||
return Constants.sectionHeaderHeightHidden
|
||||
}
|
||||
|
||||
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
|
||||
tableView.deselectRow(at: indexPath, animated: true)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user