lightContent always sets BG to black, default always sets BG to white

This commit is contained in:
Jesse MacFadyen 2014-03-11 15:24:18 -07:00
parent 20da4198f9
commit fa8aa9869d

View File

@ -65,6 +65,8 @@ namespace WPCordovaClassLib.Cordova.Commands
{
bool isVis = SystemTray.IsVisible;
// TODO: pass this to JS
//Debug.WriteLine("Result::" + res);
DispatchCommandResult(new PluginResult(PluginResult.Status.OK, isVis));
});
}
@ -77,19 +79,21 @@ namespace WPCordovaClassLib.Cordova.Commands
{ //exec(null, null, "StatusBar", "styleDefault", []);
Deployment.Current.Dispatcher.BeginInvoke(() =>
{
SystemTray.BackgroundColor = Colors.White;
SystemTray.ForegroundColor = Colors.Black;
SystemTray.Opacity = 1.0d;
SystemTray.ForegroundColor = (Color)Application.Current.Resources["PhoneForegroundColor"];
SystemTray.BackgroundColor = (Color)Application.Current.Resources["PhoneChromeColor"];
});
}
public void styleLightContent(string options)
{ //exec(null, null, "StatusBar", "styleLightContent", []);
Deployment.Current.Dispatcher.BeginInvoke(() =>
{
SystemTray.BackgroundColor = Colors.Black;
SystemTray.ForegroundColor = Colors.White;
SystemTray.Opacity = 1.0d;
SystemTray.ForegroundColor = SystemColors.ControlLightColor;
SystemTray.BackgroundColor = SystemColors.ControlDarkColor;
});
}
@ -105,7 +109,7 @@ namespace WPCordovaClassLib.Cordova.Commands
public void backgroundColorByName(string options)
{ //exec(null, null, "StatusBar", "backgroundColorByName", [colorname]);
// this should NOT be called, js should now be using/converting color names to hex
}
public void backgroundColorByHexString(string options)