Tabnine Logo
PreferenceFragment.getPreferenceScreen
Code IndexAdd Tabnine to your IDE (free)

How to use
getPreferenceScreen
method
in
android.preference.PreferenceFragment

Best Java code snippets using android.preference.PreferenceFragment.getPreferenceScreen (Showing top 2 results out of 315)

origin: Drippler/drip-steps

public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
  Fragment fragment = getFragmentManager().findFragmentByTag(FRAGMENT_TAG);
  if (fragment instanceof PreferenceFragment) {
    initSummary(((PreferenceFragment) fragment).getPreferenceScreen());
  }
}
origin: wasdennnoch/AndroidN-ify

  @Override
  protected void afterHookedMethod(MethodHookParam param) throws Throwable {
    PreferenceFragment fragment = (PreferenceFragment) param.thisObject;
    if (XposedHelpers.getAdditionalInstanceField(fragment, KEY_APP_DETAILS_CATEGORY) == null) {
      Activity context = fragment.getActivity();
      ResourceUtils res = ResourceUtils.getInstance(context);
      PreferenceScreen root = fragment.getPreferenceScreen();
      PreferenceCategory storeCat = new PreferenceCategory(context);
      storeCat.setTitle(res.getString(R.string.store));
      root.addPreference(storeCat);
      Preference appDetailsPreference = new Preference(context);
      appDetailsPreference.setTitle(res.getString(R.string.app_details));
      appDetailsPreference.setEnabled(false);
      appDetailsPreference.setKey(KEY_APP_DETAILS);
      storeCat.addPreference(appDetailsPreference);
      XposedHelpers.setAdditionalInstanceField(fragment, KEY_APP_DETAILS_CATEGORY, storeCat);
    }
  }
};
android.preferencePreferenceFragmentgetPreferenceScreen

Popular methods of PreferenceFragment

  • onCreate
  • onResume
  • onPause
  • onDestroy
  • onOptionsItemSelected
  • onActivityCreated
  • onStart
  • onAttach
  • onPreferenceTreeClick
  • onCreateView
  • onStop
  • onActivityResult
  • onStop,
  • onActivityResult,
  • onViewCreated,
  • onDestroyView,
  • onDetach,
  • getActivity,
  • onSaveInstanceState,
  • addPreferencesFromResource,
  • onCreateOptionsMenu

Popular in Java

  • Making http requests using okhttp
  • setContentView (Activity)
  • scheduleAtFixedRate (Timer)
  • onRequestPermissionsResult (Fragment)
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • ConnectException (java.net)
    A ConnectException is thrown if a connection cannot be established to a remote host on a specific po
  • Locale (java.util)
    Locale represents a language/country/variant combination. Locales are used to alter the presentatio
  • HttpServletRequest (javax.servlet.http)
    Extends the javax.servlet.ServletRequest interface to provide request information for HTTP servlets.
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now