2

I'm trying to integrate a TimePicker into the preferences screen like the one on a Lollipop device's Date&Time settings screen :

enter image description here

These are my classes so far :

public class SettingsFragment extends android.support.v7.preference.PreferenceFragmentCompat

public class TimePreferenceDialogFragmentCompat extends android.support.v7.preference.PreferenceDialogFragmentCompat

TimeDialogPreference extends android.support.v7.preference.DialogPreference

I've found sample code for android.preference.DialogPreference on the net but I couldn't find any support.v7 code samples. There are only bits and pieces on the net explaining only partially what I want to do. The best solution was posted here in this post but unfortunately it doesn't contain enough information.

Can anybody provide a sample implementation and / or link to a tutorial/working sample for the v7 support library preference dialog API ?

Community
  • 1
  • 1
Wolf359
  • 2,620
  • 4
  • 42
  • 62

0 Answers0