UI: iOS: Show on-demand state in 'Status' if there are on-demand rules
Signed-off-by: Roopesh Chander <roop@roopc.net>
This commit is contained in:
@@ -57,6 +57,7 @@
|
||||
"tunnelStatusWaiting" = "Waiting";
|
||||
|
||||
"tunnelStatusAddendumOnDemand" = " (On Demand)";
|
||||
"tunnelStatusOnDemandDisabled" = "On Demand Disabled";
|
||||
|
||||
"macToggleStatusButtonActivate" = "Activate";
|
||||
"macToggleStatusButtonActivating" = "Activating…";
|
||||
|
||||
@@ -365,6 +365,11 @@ extension TunnelDetailTableViewController {
|
||||
cell.switchView.isUserInteractionEnabled = (status == .inactive || status == .active)
|
||||
cell.isEnabled = (status == .inactive || status == .active)
|
||||
}
|
||||
|
||||
if tunnel.hasOnDemandRules && !isOnDemandEngaged && status == .inactive {
|
||||
text = tr("tunnelStatusOnDemandDisabled")
|
||||
}
|
||||
|
||||
cell.textLabel?.text = text
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user