-
Notifications
You must be signed in to change notification settings - Fork 613
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Android back button callback? #13
Comments
Maybe I'm missing something but isn't Thank you for noticing the |
Thanks for the quick reply! The thing is that I don't think I can tell that |
I think I got it now :) If it doesn't work I guess another solution would be making this component close when changing it's |
I have a listener for back button at the very "top level" of my app, and when I set Not sure I follow what you meant by closing when changing |
Honestly, I wanted to preserve Thanks! |
Released on v2.2.0, closing! |
By default, the Android Back button will close the modal. Looking at the code I found the (undocumented?)
hideOnBack
property which disabled this.The behavior I'm after is a bit different: I'm presenting the user with an alert modal, on top of an existing scene, that will explain what needs to be done. What I'd like to happen is that if Back is pressed, then the app will navigate to the earlier scene (i.e. not just close the modal and stay at the same scene, but go back to the previous scene).
I was hoping that a close callback would allow me to do this (by simulating a Back press), but I don't think I can tell whether the modal was closed as a result of the Back button or not. Is there a way to achieve this?
The text was updated successfully, but these errors were encountered: