mirror of
https://codeberg.org/comaps/comaps
synced 2026-01-06 12:34:24 +00:00
Compare commits
2 Commits
8cffa508f3
...
yannikblos
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
34bb81e516 | ||
|
|
3035116fec |
@@ -41,13 +41,14 @@ final class ThemeManager: NSObject {
|
|||||||
}
|
}
|
||||||
}(actualTheme)
|
}(actualTheme)
|
||||||
|
|
||||||
if Settings.mapAppearance == .light {
|
let isCarPlayActive = CarPlayService.shared.isCarplayActivated
|
||||||
|
if !isCarPlayActive, Settings.mapAppearance == .light {
|
||||||
if actualTheme == .vehicleDay || actualTheme == .vehicleNight {
|
if actualTheme == .vehicleDay || actualTheme == .vehicleNight {
|
||||||
FrameworkHelper.setTheme(.vehicleDay)
|
FrameworkHelper.setTheme(.vehicleDay)
|
||||||
} else {
|
} else {
|
||||||
FrameworkHelper.setTheme(.day)
|
FrameworkHelper.setTheme(.day)
|
||||||
}
|
}
|
||||||
} else if Settings.mapAppearance == .dark {
|
} else if !isCarPlayActive, Settings.mapAppearance == .dark {
|
||||||
if actualTheme == .vehicleDay || actualTheme == .vehicleNight {
|
if actualTheme == .vehicleDay || actualTheme == .vehicleNight {
|
||||||
FrameworkHelper.setTheme(.vehicleNight)
|
FrameworkHelper.setTheme(.vehicleNight)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ import AVFoundation
|
|||||||
return mapAppearance
|
return mapAppearance
|
||||||
}
|
}
|
||||||
|
|
||||||
return .auto
|
return .light
|
||||||
}
|
}
|
||||||
set {
|
set {
|
||||||
UserDefaults.standard.set(newValue.rawValue, forKey: userDefaultsKeyMapAppearance)
|
UserDefaults.standard.set(newValue.rawValue, forKey: userDefaultsKeyMapAppearance)
|
||||||
|
|||||||
Reference in New Issue
Block a user