Some cleanup especially regarding method references (#516)

* Remove superfluous method arguments in method references

* Use 'Self' for internal static access

* Convert static to instance field in singleton class

* Remove class name prefix in references to local methods

* Remove nested frameworks in all extensions and frameworks
This commit is contained in:
Danny Mösch 2021-10-03 05:46:07 +02:00 committed by GitHub
parent e1cbcb5d7a
commit 32b7c9b635
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 57 additions and 57 deletions

View file

@ -16,7 +16,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(hideUnknownSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(hideUnknownSwitchAction), for: UIControl.Event.valueChanged)
return uiSwitch
}()
@ -24,7 +24,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(hideOTPSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(hideOTPSwitchAction), for: UIControl.Event.valueChanged)
return uiSwitch
}()
@ -32,7 +32,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(autoCopyOTPSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(autoCopyOTPSwitchAction), for: UIControl.Event.valueChanged)
return uiSwitch
}()
@ -40,7 +40,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(rememberPGPPassphraseSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(rememberPGPPassphraseSwitchAction), for: UIControl.Event.valueChanged)
uiSwitch.isOn = Defaults.isRememberPGPPassphraseOn
return uiSwitch
}()
@ -49,7 +49,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(rememberGitCredentialPassphraseSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(rememberGitCredentialPassphraseSwitchAction), for: UIControl.Event.valueChanged)
uiSwitch.isOn = Defaults.isRememberGitCredentialPassphraseOn
return uiSwitch
}()
@ -58,7 +58,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(enableGPGIDSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(enableGPGIDSwitchAction), for: UIControl.Event.valueChanged)
uiSwitch.isOn = Defaults.isEnableGPGIDOn
return uiSwitch
}()
@ -67,7 +67,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(showFolderSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(showFolderSwitchAction), for: UIControl.Event.valueChanged)
uiSwitch.isOn = Defaults.isShowFolderOn
return uiSwitch
}()
@ -76,7 +76,7 @@ class GeneralSettingsTableViewController: BasicStaticTableViewController {
let uiSwitch = UISwitch()
uiSwitch.onTintColor = Colors.systemBlue
uiSwitch.sizeToFit()
uiSwitch.addTarget(self, action: #selector(hidePasswordImagesSwitchAction(_:)), for: UIControl.Event.valueChanged)
uiSwitch.addTarget(self, action: #selector(hidePasswordImagesSwitchAction), for: UIControl.Event.valueChanged)
uiSwitch.isOn = Defaults.isHidePasswordImagesOn
return uiSwitch
}()