I have implemented the onPreferenceClick(Preference) callback
interface
[code]
    public boolean onPreferenceClick(Preference arg0) {

        if (arg0 instanceof ListPreference){
                addListPreferenceEntriesFromStore((ListPreference) arg0,
getSharedPreferences("cfn_preferences", MODE_PRIVATE));
        }

        else if (arg0 instanceof EditTextPreference){
                ((EditTextPreference)arg0).setTitle("Hallabalooo");
                ((EditTextPreference)arg0).setDialogTitle("Tjillevipp");
        }

        return true;
    }
[/code]

When I tap the EditTextPreference for the first time the title, in the
PreferenceScreen, is changed as expected but the dialog title isn't.
The second time I tap the EditTextPreference the dialog title is also
updated.

I experience the same behaviour with the ListPreference. The
addListPreferenceEntriesFromStore() method updates the contents of the
ListPreference, but the change isn't visible the first time the
ListPreference is displayed.

It seems like changes made to the dialog part of a preference during
the context of the onPreferenceClick() callback doesn't show.

What is it I do wrong here? Or is there a workaround?

Thankful for any help

/Mathias

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to