这里记录如何获取系统背景主题是黑色还是白色

C#:

Visibility darkBackgroundVisibility =(Visibility)Application.Current.Resources["PhoneDarkThemeVisibility"];

// Write the theme background value.
if (darkBackgroundVisibility == Visibility.Visible)
{
    theme = "black";
}
else
{
    theme = "white";
}

来源:http://msdn.microsoft.com/zh-cn/ff769545#BKMK_DeterminingThemeBackgroundAndAccentColor

相关文章:

  • 2022-12-23
  • 2021-09-01
  • 2021-10-29
  • 2022-01-06
  • 2021-10-07
  • 2022-12-23
  • 2021-09-23
猜你喜欢
  • 2021-09-04
  • 2022-12-23
  • 2021-07-14
  • 2021-10-16
  • 2021-06-25
  • 2021-05-31
  • 2022-12-23
相关资源
相似解决方案