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

onClose callback cannot be cancelled out of. #65

Open
davidemerritt opened this issue Mar 2, 2016 · 0 comments
Open

onClose callback cannot be cancelled out of. #65

davidemerritt opened this issue Mar 2, 2016 · 0 comments

Comments

@davidemerritt
Copy link

it seems that that you cannot cancel out of the onClose callback with any combination of return false/stopPropogation because s.unbindEvents is being called (line 675) before the callback is run.

A simple proposal that wouldn't change existing behavior is the to move unbindEvents inside the if blocks for callback/non-callback closing, continue always calling it in the case of no callback, and call it unless the callback returns false when inside the callback branch of that if statement. If this seems reasonable, I'll make a PR.

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

1 participant