Dianne, could you perhaps comment on this, since you seem to be the person who actually developed this fragment stuff.
Thanks. On Apr 5, 2:27 pm, Zsolt Vasvari <zvasv...@gmail.com> wrote: > I am trying to replace the setPreferenceScreen() functionality to > switch to a particular header of my new style Preference Activity. > > I cannot find a straightforward way of doing is. > > Currently, I am saving the list of headers: > > @Override > public void onBuildHeaders(List<Header> target) > { > loadPreferenceHeadersFromResource(R.xml.id, target); > > this.headers = target; > } > > Then searching for and setting the appropriate one: > > private void switchToHeaderByFragment(Class<?> fragmentClass) > { > for (Header header : this.headers) > if (header.fragment.equals(fragmentClass.getName())) > { > switchToHeader(header); > break; > } > } > > There has to be a better way? What am I missing? -- 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