I know how to call a function inside a fragment to an activity,
(activity as MainActivity).bbtn()
however I am wondering how/can I call this function from another activity? As ideally I want to separate what each activity does and would rather an activity that only handled media player to run these commands. At the moment it is looking like I will need to put a lot of my core logic into the MainActivity which could potentially be a lot of unused code.