Created
January 24, 2019 15:46
-
-
Save wellingtoncosta/48d5f8aacbac08ef92fef0428f1f007f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class FragmentOne : Fragment() { | |
override fun onCreateView( | |
inflater: LayoutInflater, container: ViewGroup?, | |
savedInstanceState: Bundle? | |
): View? { | |
return inflater.inflate(R.layout.fragment_fragment_one, container, false).apply { | |
this.go_to_fragment_two.setOnClickListener { | |
RxBus.instance.publish(MAIN_ACTIVITY_SUBJECT, FRAGMENT_TWO_TAG) | |
} | |
this.finish_app.setOnClickListener { | |
RxBus.instance.publish(MAIN_ACTIVITY_SUBJECT, FINISH_APP_TAG) | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment