开发者

ListPreference in Fragment

开发者 https://www.devze.com 2023-03-24 18:14 出处:网络
I want to show a ListPreference inside a Fragment. The ListPreference is the same as used in a standalone settings Activity. But I can\'t figure out how to directly open the ListPreference view from t

I want to show a ListPreference inside a Fragment.

The ListPreference is the same as used in a standalone settings Activity. But I can't figure out how to directly open the ListPreference view from the fragment (without showing the whole Settings view).

I found there exists a class DialogFragment, but does it work for that use case?

Note tha开发者_如何学Ct I'm using the compatibility version of Fragment API. The class PreferenceFragment is not available there.


But I can't figure out how to directly open the ListPreference view from the fragment (without showing the whole Settings view).

AFAIK, this is not supported on any version of Android.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号