-
Notifications
You must be signed in to change notification settings - Fork 72
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
onRequestPermissionResult and onActivityResult support #63
Comments
you can make methods / functions in screen/ basescreenview to pass data to the screen from on activity with when / switch case statements implemented in onActivityResult or onRequestPermissionResult. use language features like abstraction in this case rather getting it implemented in the library. |
Methods like this should be in the library. Every single app which is non-trivial needs to deal with permission and going to write same useless repetitive logic on their end (it needs a change in both Also, keeping in library creates a much better abstraction. Conductor does this and is one of the issues as mentioned in this Reddit thread (I'm not sure why their implementation is so complex, why can't permission or activity result be just delegated to the topmost screen). The only reason it should not be in the library is that the author doesn't need it and anyone can fork and add it to their version. |
It's true that we want to be careful about adding too much in the lib, but in this case I agree that this should be part of the library. |
Agreed. I think a very simple implementation will make life much easier for other devs. I tried implementing it in a PR #64 and would love to make it even more simple. |
onRequestPermissionResult
andonActivityResult
support in Screen. These methods propagate the request to activity and then propagate the result back to correct screen.It will make it much easier for the implementors of Screen.
The text was updated successfully, but these errors were encountered: