Fix StatusBar on iOS
This commit is contained in:
parent
ca08dbd780
commit
6f57946ab0
@ -104,15 +104,25 @@ if (getStorage("alertvolume") == null) {
|
||||
function setAppTheme(theme) {
|
||||
if (theme == "light") {
|
||||
$("#app").removeClass("theme-dark");
|
||||
if (platform_type == "cordova" && cordova.platformId == 'android' && typeof StatusBar !== 'undefined') {
|
||||
StatusBar.styleDefault();
|
||||
StatusBar.backgroundColorByHexString("#E0E0E0");
|
||||
if (platform_type == "cordova" && typeof StatusBar !== 'undefined') {
|
||||
if (cordova.platformId == 'android') {
|
||||
StatusBar.styleDefault();
|
||||
StatusBar.backgroundColorByHexString("#E0E0E0");
|
||||
} else if (cordova.platformId == 'ios') {
|
||||
StatusBar.styleDefault();
|
||||
StatusBar.backgroundColorByHexString("#F6F6F6");
|
||||
}
|
||||
}
|
||||
} else if (theme == "dark" || theme == "oleddark") {
|
||||
$("#app").addClass("theme-dark");
|
||||
if (platform_type == "cordova" && cordova.platformId == 'android' && typeof StatusBar !== 'undefined') {
|
||||
StatusBar.styleLightContent();
|
||||
StatusBar.backgroundColorByHexString("#000000");
|
||||
if (platform_type == "cordova" && typeof StatusBar !== 'undefined') {
|
||||
if (cordova.platformId == 'android') {
|
||||
StatusBar.styleLightContent();
|
||||
StatusBar.backgroundColorByHexString("#000000");
|
||||
} else if (cordova.platformId == 'ios') {
|
||||
StatusBar.styleLightContent();
|
||||
StatusBar.backgroundColorByHexString("#161616");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user