سؤال

I want to programmatically change the text color of all ListPreference in my PreferenceActivity, after the layout is constructed (so after onCreate). Basically I want to be able to toggle all text between black and white.

I've tried having two themes for both colors, but that requires to restart the activity to toggle between themes. I don't want that.

Can someone come up with a solution to this problem?

هل كانت مفيدة؟

المحلول

I guess the answer to my question is that there is no way to do what I wanted. I ended up using two themes for both colors, even though changing the theme will apply after restarting the activity.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top