change positions of switch and detailed buttion
This commit is contained in:
parent
ad64944648
commit
5399f2be48
1 changed files with 2 additions and 2 deletions
|
|
@ -32,8 +32,8 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
|
||||||
hideUnknownSwitch.onTintColor = UIColor(displayP3Red: 0, green: 122.0/255, blue: 1, alpha: 1)
|
hideUnknownSwitch.onTintColor = UIColor(displayP3Red: 0, green: 122.0/255, blue: 1, alpha: 1)
|
||||||
hideUnknownSwitch.sizeToFit()
|
hideUnknownSwitch.sizeToFit()
|
||||||
let detailButton = UIButton(type: .detailDisclosure)
|
let detailButton = UIButton(type: .detailDisclosure)
|
||||||
hideUnknownSwitch.frame = CGRect(x: 0, y: 0, width: hideUnknownSwitch.bounds.width, height: hideUnknownSwitch.bounds.height)
|
hideUnknownSwitch.frame = CGRect(x: detailButton.bounds.width+10, y: 0, width: hideUnknownSwitch.bounds.width, height: hideUnknownSwitch.bounds.height)
|
||||||
detailButton.frame = CGRect(x: hideUnknownSwitch.bounds.width+10, y: 5, width: detailButton.bounds.width, height: detailButton.bounds.height)
|
detailButton.frame = CGRect(x: 0, y: 5, width: detailButton.bounds.width, height: detailButton.bounds.height)
|
||||||
detailButton.addTarget(self, action: #selector(GeneralSettingsTableViewController.tapHideUnknownSwitchDetailButton(_:)), for: UIControlEvents.touchDown)
|
detailButton.addTarget(self, action: #selector(GeneralSettingsTableViewController.tapHideUnknownSwitchDetailButton(_:)), for: UIControlEvents.touchDown)
|
||||||
let accessoryView = UIView(frame: CGRect(x: 0, y: 0, width: detailButton.bounds.width + hideUnknownSwitch.bounds.width+10, height: hideUnknownSwitch.bounds.height))
|
let accessoryView = UIView(frame: CGRect(x: 0, y: 0, width: detailButton.bounds.width + hideUnknownSwitch.bounds.width+10, height: hideUnknownSwitch.bounds.height))
|
||||||
accessoryView.addSubview(detailButton)
|
accessoryView.addSubview(detailButton)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue