List of usage examples for android.app Activity toString
@Override
public String toString()
From source file:de.elanev.studip.android.app.backend.net.oauth.SignInFragment.java
@Override public void onAttach(Activity activity) { Log.i(TAG, "onAttach Called!"); super.onAttach(activity); try {/*from w w w. j a va 2 s. co m*/ mCallbacks = (OnRequestTokenReceived) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + "must implement OnWebViewAuthListener"); } }
From source file:com.lastsoft.plog.GamesFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); mActivity = activity;// w ww. j a v a 2 s .c om try { mListener = (OnFragmentInteractionListener) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + " must implement OnFragmentInteractionListener"); } }
From source file:org.anhonesteffort.flock.ServerTestsFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); if (activity instanceof SetupActivity) this.setupActivity = (SetupActivity) activity; else//w ww . java2s . c om throw new ClassCastException(activity.toString() + " not what I expected D: !"); }
From source file:com.cerema.cloud2.ui.fragment.ShareFileFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); try {/*from w ww .ja v a2 s . c om*/ mListener = (ShareFragmentListener) activity; } catch (ClassCastException e) { throw new ClassCastException( activity.toString() + " must implement OnShareFragmentInteractionListener"); } }
From source file:br.liveo.ndrawer.ui.fragment.MainFragment31.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); // This makes sure that the container activity has implemented // the callback interface. If not, it throws an exception try {// www. ja v a 2 s. co m mCallback = (OnMainFragment31SelectedListener) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + " must implement OnMainFragment32SelectedListener"); } }
From source file:org.gnucash.android.ui.account.AccountsListFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); try {//from w w w . java 2 s. c o m mAccountSelectedListener = (OnAccountClickedListener) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + " must implement OnAccountSelectedListener"); } }
From source file:net.globide.creepypasta_files_07.BrowseListFragment.java
/** * Implements onAttach()./*from www . jav a 2 s .co m*/ */ @Override public void onAttach(Activity activity) { super.onAttach(activity); try { // When the fragment is added to the display screen, have this // class's // mListener property reference the host activity's // OnBrowseTouchListener // implementation. This allows this fragment to both fire events to // the // host activity AND forces activities using this fragment to // implement // OnBrowseTouchListener. mListener = (OnBrowseListTouchListener) activity; } catch (ClassCastException e) { // If the class using this fragment is NOT implementing // OnBrowseTouchListener, throw an exception. throw new ClassCastException(activity.toString() + " must implement OnBrowseListTouchListener"); } }
From source file:cz.muni.fi.japanesedictionary.fragments.DisplayTranslation.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); try {//from w w w. j av a 2 s. co m mCallbackTranslation = (OnCreateTranslationListener) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + " must implement OnCreateTranslationListener"); } }
From source file:net.simonvt.cathode.ui.fragment.ShowFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); try {//from ww w. ja v a 2s .c om navigationCallbacks = (ShowsNavigationListener) activity; } catch (ClassCastException e) { throw new ClassCastException(activity.toString() + " must implement ShowsNavigationListener"); } }
From source file:com.nikhilnayak.games.octoshootar.ui.fragments.GameScoreFragment.java
@Override public void onAttach(Activity activity) { super.onAttach(activity); mAttachTime = System.currentTimeMillis(); if (activity instanceof GameScoreFragment.Listener) { mListener = (GameScoreFragment.Listener) activity; mPlayerProfile = new PlayerProfile( activity.getSharedPreferences(PlayerProfile.SHARED_PREFERENCES_NAME, Context.MODE_PRIVATE)); } else {//from w ww .j a v a 2 s .c om throw new ClassCastException(activity.toString() + " must implement GameScoreFragment.Listener"); } }