如何在全屏嵌套的Andr​​oid preferenceScreen show(没有系统标题栏) [英] how to make the nested Android PreferenceScreen show in Full Screen(without titlebar in system)

查看:227
本文介绍了如何在全屏嵌套的Andr​​oid preferenceScreen show(没有系统标题栏)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须写一个preferenceActivity,它包含嵌套子preferenceScreen。问题是我想要让他们全屏,我在AndroidManifest添加theme.fullscreen和它的作品,但是当我在分项之一点击进入一个嵌套的preferenceScreen,出现在标题栏。现在我不知道如何让嵌套全屏了。
我已经看源$ C ​​$ C为preferenceScreen寻求帮助。它表明嵌套preferenceScreen被显示在一个对话框,而且我发现code哪些新的对话框中方法的ShowDialog。

I have write an PreferenceActivity and it contains nested child PreferenceScreen. the problem is i want made them FullScreen, i've add theme.fullscreen in AndroidManifest and it works, but when i click on one of the sub-item to enter an nested PreferenceScreen, the title bar appears. and now i didn't know how to make the nested full screen too. and i've look source code for PreferenceScreen to find help. it shows that nested preferenceScreen was showed on an Dialog, and i found the code which new the Dialog in method showDialog.

Dialog dialog = mDialog = new Dialog(context, TextUtils.isEmpty(title)
            ? com.android.internal.R.style.Theme_NoTitleBar
            : com.android.internal.R.style.Theme);

似乎noway要做到这一点,但我真的想知道的是任何人都可以在一个preferenceActivity实现这一点。

it seems that noway to do that, but i really want to know is anyone can implement this in one PreferenceActivity.

推荐答案

这是在android系统中的错误看到<一个href=\"http://$c$c.google.com/p/android/issues/detail?id=4611&can=1&q=$p$pferencescreen%20theme&colspec=ID%20Type%20Status%20Owner%20Summary%20Stars\"相对=nofollow>错误报告。

This is a bug in android see the Bug Report.

有一种变通方法这里通过添加preferenceFromIntent()。

There is a workaround here by using addPreferenceFromIntent().

这篇关于如何在全屏嵌套的Andr​​oid preferenceScreen show(没有系统标题栏)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆