mirror of
https://github.com/Toxblh/MTMR.git
synced 2026-01-11 17:38:38 +00:00
-
This commit is contained in:
parent
76934e6ff0
commit
cd8b595552
@ -83,7 +83,7 @@ class SupportedTypesHolder {
|
|||||||
return (item: .weather(interval: interval ?? 1800.00, units: units ?? "metric", api_key: api_key ?? "32c4256d09a4c52b38aecddba7a078f6", icon_type: icon_type ?? "text"), action: action, parameters: [:])
|
return (item: .weather(interval: interval ?? 1800.00, units: units ?? "metric", api_key: api_key ?? "32c4256d09a4c52b38aecddba7a078f6", icon_type: icon_type ?? "text"), action: action, parameters: [:])
|
||||||
},
|
},
|
||||||
"currency": { decoder in
|
"currency": { decoder in
|
||||||
enum CodingKeys: String, CodingKey { case refreshInterval; case from; case to; case action }
|
enum CodingKeys: String, CodingKey { case refreshInterval; case from; case to }
|
||||||
let container = try decoder.container(keyedBy: CodingKeys.self)
|
let container = try decoder.container(keyedBy: CodingKeys.self)
|
||||||
let interval = try container.decodeIfPresent(Double.self, forKey: .refreshInterval)
|
let interval = try container.decodeIfPresent(Double.self, forKey: .refreshInterval)
|
||||||
let from = try container.decodeIfPresent(String.self, forKey: .from)
|
let from = try container.decodeIfPresent(String.self, forKey: .from)
|
||||||
|
|||||||
@ -225,7 +225,7 @@ class TouchBarController: NSObject, NSTouchBarDelegate {
|
|||||||
case .openUrl(url: let url):
|
case .openUrl(url: let url):
|
||||||
return {
|
return {
|
||||||
if let url = URL(string: url), NSWorkspace.shared.open(url) {
|
if let url = URL(string: url), NSWorkspace.shared.open(url) {
|
||||||
print("URL was successfully opened")
|
// print("URL was successfully opened")
|
||||||
} else {
|
} else {
|
||||||
print("error", url)
|
print("error", url)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user