Skip to content
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

Can we trigger event during close image picker modal #177

Closed
LSmint opened this issue Apr 14, 2018 · 2 comments
Closed

Can we trigger event during close image picker modal #177

LSmint opened this issue Apr 14, 2018 · 2 comments
Assignees

Comments

@LSmint
Copy link

LSmint commented Apr 14, 2018

I would like to perform some script after user tapped the modal close button, can we add Promise reject function to return a catch result during trigger the cancel event?

In imagepicker.ios.js file:

ImagePickerControllerDelegate.prototype.qb_imagePickerControllerDidCancel = function (imagePickerController) {
        this._reject("cancelled"); <--- add something like this
        imagePickerController.dismissViewControllerAnimatedCompletion(true, null);
    };
@LSmint LSmint changed the title Can we trigger during image picker modal close event Can we trigger event during close image picker modal Apr 14, 2018
@ghost ghost assigned tbozhikov Apr 16, 2018
@ghost ghost added the new PR label Apr 16, 2018
@ghost ghost removed the new PR label Apr 16, 2018
@tbozhikov tbozhikov reopened this Apr 16, 2018
@zbranzov zbranzov self-assigned this Apr 17, 2018
@zbranzov
Copy link
Contributor

The fix is released in v6.0.1 of the plugin. Enjoy!

@ghost ghost removed the ready for test label Apr 17, 2018
@lucasumberto
Copy link

lucasumberto commented Mar 5, 2021

Hi!

On iOS, when the picker is dismissed by native gesture (pushing it down) the close event is not fired like the close button. Would be nice if it fires this event (Error: Canceled) too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants