I am in need of checking the consistency between a couple of values of
default shared preferences, while using the default preference
activity.

An example is a send mail option which needs a target mail address to
be valid.

What I am going to implement is a OnSharedPreferenceChangeListener in
the preferences activity (the one that calls the
addPreferencesFromResource() method, and if some check fails, push
back the change and notify the user with a dialog.

Now my question is: is there a smarter way to implement these checks?
Do you have any suggestions?

And more: will the onSharedPreferenceChanged be called only if the
activity which registers it is visible? Just to be sure I will
unregister the listener in onPause().

Many thanks

-- 
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