如何使PhoneGap的应用程序的背景透明,揭示当前系统壁纸 [英] How to make the PhoneGap app's background transparent and revealing the current system wallpaper
本文介绍了如何使PhoneGap的应用程序的背景透明,揭示当前系统壁纸的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
东西我已经做了:
1.设置主要活动的主题
安卓主题=@安卓风格/ Theme.Wallpaper.NoTitleBar
2.设置由PhoneGap的创建web视图的背景
appView.setBackgroundColor(Color.TRANSPARENT);
3.设定身体和HTML标签的背景
HTML,
身体{
背景颜色:透明;
}
不过,我的应用程序仍然有一个黑色的背景,为什么???
解决方案
@覆盖
公共无效的onCreate(捆绑savedInstanceState)
{
super.setIntegerProperty(的backgroundColor,Color.TRANSPARENT);
...
}
Something I have done:
1.set the theme of the main activity
android:theme="@android:style/Theme.Wallpaper.NoTitleBar"
2.set the background of the webview created by phoneGap
appView.setBackgroundColor(Color.TRANSPARENT);
3.set the background of the body and html tag
html,
body{
background-color: transparent;
}
But, my app still has a black background, why ???
解决方案
@Override
public void onCreate(Bundle savedInstanceState)
{
super.setIntegerProperty("backgroundColor", Color.TRANSPARENT);
...
}
这篇关于如何使PhoneGap的应用程序的背景透明,揭示当前系统壁纸的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文