Fix DNS/proxy loading current settings too late

This commit is contained in:
Davide De Rosa 2021-01-22 17:49:31 +01:00
parent 0a9beaf8e0
commit 7e4a0cdbfd
2 changed files with 4 additions and 2 deletions

View File

@ -86,6 +86,8 @@ class DNSViewController: NSViewController, ProfileCustomization {
tableDNSDomains.rightAnchor.constraint(equalTo: viewDNSDomains.rightAnchor),
])
loadSettings(from: currentChoice)
popupChoice.removeAllItems()
for choice in choices {
popupChoice.addItem(withTitle: choice.description)
@ -95,7 +97,6 @@ class DNSViewController: NSViewController, ProfileCustomization {
}
tableDNSAddresses.rowTemplate = Templates.server
tableDNSDomains.rowTemplate = Templates.domain
loadSettings(from: currentChoice)
}
// MARK: Actions

View File

@ -80,6 +80,8 @@ class ProxyViewController: NSViewController, ProfileCustomization {
tableProxyBypass.rightAnchor.constraint(equalTo: viewProxyBypass.rightAnchor),
])
loadSettings(from: currentChoice)
popupChoice.removeAllItems()
for choice in choices {
popupChoice.addItem(withTitle: choice.description)
@ -88,7 +90,6 @@ class ProxyViewController: NSViewController, ProfileCustomization {
}
}
tableProxyBypass.rowTemplate = Templates.bypass
loadSettings(from: currentChoice)
}
// MARK: Actions