Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (context instanceof MainFragmentListener)
- @Override
- public void onAttach(Context context) {
- super.onAttach(context);
- if (context instanceof MainFragmentListener) {
- mListener = (MainFragment.MainFragmentListener) context;
- } else {
- throw new RuntimeException(context.toString()
- + " must implement OnFragmentInteractionListener");
- }
- }
Add Comment
Please, Sign In to add comment