Reputation: 1170
I have a FragmentActivity as my main activity. I am trying to call up a "user preferences" screen to record some preferences. It seems that I need to call the PreferenceActivity from an Activity (as opposed to a FragmentActivity). Is there an alternative to call a PreferenceActivity from a FragmentActivity?
Edit: I am using the compatibility package
Upvotes: 1
Views: 707
Reputation: 1007399
Is there an alternative to call a PreferenceActivity from a FragmentActivity?
No, sorry, PreferenceActivity
only supports native fragments on Android 3.x and higher. With some care, you can craft preference XML and activities that will support both fragments on supported devices and a classic PreferenceActivity
on older devices. Here is a sample project demonstrating this.
Upvotes: 2