如何将首选项屏幕隐藏在第二个屏幕后面?
我有两个 PreferenceScreen
。 我使用主题 android:theme="@android:style/Theme.Light.WallpaperSettings
。 因此,当我加载第二个布局时,第一个布局可以在第二个布局下看到。
我想隐藏第一个首选项屏幕,而不是删除它。我怎样才能做到这一点?
I have two PreferenceScreen
.
I use the theme android:theme="@android:style/Theme.Light.WallpaperSettings
.
So when I load the second layout, the first layout can be seen under the second layout.
I want to hide the first preference screen, not remove it. How can I do that?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您有一个 onClick 或其他方法将您发送到第二个首选项屏幕,则在此方法中您可以调用:
要更改后台活动的视图,
也不要忘记在 onResume() 中重置它;
If you have an onClick or other method that sends you to the second preference screen, in this method you could call:
to change the view of the activity in the background
also don't forget to reset it when in your onResume();