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

How to use
onAttach
method
in
android.preference.PreferenceFragment

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

origin: trello/RxLifecycle

@Override
@CallSuper
public void onAttach(android.app.Activity activity) {
  super.onAttach(activity);
  lifecycleSubject.onNext(FragmentEvent.ATTACH);
}
origin: ukanth/afwall

@Override
public void onAttach(Context context) {
  super.onAttach(context);
  ctx = context;
}
origin: ukanth/afwall

@Override
public void onAttach(Context context) {
  super.onAttach(context);
  ctx = context;
}
origin: ukanth/afwall

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
  if(Build.VERSION.SDK_INT < Build.VERSION_CODES.M){
    ctx = activity;
  }
}
origin: malmstein/yahnac

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
  this.listener = (Listener) activity;
}
origin: grzegorznittner/chanu

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
}
origin: DF1E/SimpleExplorer

@Override
public void onAttach(final Activity activity) {
  super.onAttach(activity);
  if (!(activity instanceof SettingsActivity)) {
    throw new RuntimeException("Should be attached only to SettingsActivity");
  }
}
origin: sylvek/itracing2

@Override
public void onAttach(Activity activity)
{
  super.onAttach(activity);
  if (activity instanceof OnPreferencesListener) {
    this.presenter = (OnPreferencesListener) activity;
  } else {
    throw new ClassCastException("must implement OnPreferencesListener");
  }
}
origin: kochka/WeightLogger

@Override
public void onAttach(Activity activity) {
 super.onAttach(activity);
 if (activity instanceof Callback) {
  mCallback = (Callback) activity;
 } else {
  throw new IllegalStateException("URLCallback interface not implement");
 }
}
origin: sylvek/itracing2

@Override
public void onAttach(Activity activity)
{
  super.onAttach(activity);
  if (activity instanceof OnDevicePreferencesListener) {
    this.presenter = (OnDevicePreferencesListener) activity;
  } else {
    throw new ClassCastException("must implement OnDevicePreferencesListener");
  }
}
origin: antest1/kcanotify

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
  if (activity instanceof Callback) {
    mCallback = (Callback) activity;
  } else {
    throw new IllegalStateException("callback interface not implemented");
  }
}
origin: vbier/habpanelviewer

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
  if (activity instanceof PreferenceCallback) {
    mCallback = (PreferenceCallback) activity;
  } else {
    throw new IllegalStateException("Owner must implement Callback interface");
  }
}
origin: fg607/RelaxFinger

@Override
public void onAttach(Context context) {
  super.onAttach(context);
  mContext = context;
  mActivity = (SettingActivity) getActivity();
}
origin: adblockplus/libadblockplus-android

@Override
public void onAttach(Activity activity)
{
 super.onAttach(activity);
 provider = castOrThrow(activity, Provider.class);
}
origin: TobiasBielefeld/Simple-Solitaire

  @Override
  public void onAttach(Activity activity){
    if(Build.VERSION.SDK_INT < Build.VERSION_CODES.M){
      reinitializeData(activity);
    }
    super.onAttach(activity);
  }
}
origin: fg607/RelaxFinger

@Override
public void onAttach(Activity activity) {
  super.onAttach(activity);
  mContext = activity;
  mActivity = (SettingActivity) getActivity();
}
origin: TobiasBielefeld/Simple-Solitaire

@Override
public void onAttach(Context context) {
  reinitializeData(context);
  super.onAttach(context);
}
origin: fasteque/rgb-tool

@Override
public void onAttach(Context context) {
  super.onAttach(context);
  try {
    onPreferenceSelectedListener = (OnPreferenceSelectedListener) getActivity();
  } catch (ClassCastException e) {
    throw new ClassCastException(getActivity().toString() + " must implement OnPreferenceSelectedListener");
  }
}
origin: andyiac/githot

  @Override
  public void onAttach(Activity activity) {
    super.onAttach(activity);
    if (!injected) {
      injected = true;
      Injector injector = (Injector) getActivity();
      injector.inject(this);
    }
  }
}
origin: towavephone/MemoryCleaner

@Override public void onAttach(Activity activity) {
  super.onAttach(activity);
  if (getActivity() != null && getActivity() instanceof SettingActivity) {
    this.activity = (SettingActivity) getActivity();
  }
}
android.preferencePreferenceFragmentonAttach

Popular methods of PreferenceFragment

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

Popular in Java

  • Reading from database using SQL prepared statement
  • getExternalFilesDir (Context)
  • putExtra (Intent)
  • setScale (BigDecimal)
  • InputStreamReader (java.io)
    A class for turning a byte stream into a character stream. Data read from the source input stream is
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • Arrays (java.util)
    This class contains various methods for manipulating arrays (such as sorting and searching). This cl
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Reference (javax.naming)
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Best plugins for Eclipse
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