Prevent editing of trusted network SSID

Currently possible yet ineffective. Easier than allowing renaming.
This commit is contained in:
Davide De Rosa 2021-03-31 11:20:27 +02:00
parent d2e81f0ff8
commit 57baeff530
2 changed files with 13 additions and 1 deletions

View File

@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## Unreleased
### Fixed
- Prevent ineffective editing of trusted network SSID.
## 1.15.1 (2021-02-14)
### Changed

View File

@ -83,6 +83,7 @@ class TrustedNetworksViewController: NSViewController, ProfileCustomization {
switch column.identifier {
case Columns.ssid:
column.title = "SSID"
column.isEditable = false
case Columns.trust:
column.title = L10n.App.Trusted.Columns.Trust.title
@ -181,8 +182,13 @@ extension TrustedNetworksViewController: NSTableViewDataSource, NSTableViewDeleg
guard row < model.sortedWifis.count else { // XXX
return
}
switch tableColumn?.identifier {
// case Columns.ssid:
// guard let ssidName = object as? String else {
// fatalError("Expected a String for trust SSID")
// }
// model.renameWifi(at: row, to: ssidName)
case Columns.trust:
guard let checkTrust = object as? Bool else {
fatalError("Expected a Bool for trust checkbox state")