r/android_devs • • May 18 '23

Help What's the difference between onBackInvokedDispatcher.registerOnBackInvokedCallback and onBackPressedDispatcher.addCallback?

They both seem to handle the same thing : the back key/gesture. And only one is being called.

I've watched this video and I still don't get the difference (they showed them both) :

https://youtu.be/Elpqr5xpLxQ

3 Upvotes

16 comments sorted by

View all comments

Show parent comment

1

u/AD-LB May 20 '23

I wrote "technically". This means I can do it to demonstrate it to you when it's available. I don't need to publish it to show that.