Created
July 29, 2020 21:37
-
-
Save marcherdiego/6a7596c152deba5309e9f6b4d2b5aadc 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 MainView(activity: MainActivity, private val bus: EventBus) { | |
private val activityRef = WeakReference(activity) | |
init { | |
activity.findViewById<View>(R.id.someButton_id).setOnClickListener { | |
bus.post(SomeKindOfEvent()) | |
} | |
} | |
class SomeKindOfEvent | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment