https://kotlinlang.org logo
e

edvin

08/31/2016, 9:23 PM
When I can take a look at your whole app I might suggest another approach. I suspect you don't really need the bus at all you see 🙂 Basically you can put this viewmodel in a controller and call it
selectedPhoto
or something. Bind to it in the same way as here and simply call
controller.selectedPhoto.rebind { photo = selectedItem }
to update. Everything that listens for the selected photo would be updated.