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

Event in Jquery #88

Closed
adacurro-usgs opened this issue Sep 28, 2018 · 4 comments
Closed

Event in Jquery #88

adacurro-usgs opened this issue Sep 28, 2018 · 4 comments

Comments

@adacurro-usgs
Copy link

Hi does this plugin support event handling? I wanted to freeze my markercluster on easy print button click.

Cheers! Amazing plugin tho!

@rowanwins
Copy link
Owner

Hi @adacurro-usgs

There are a couple of undocumented events in the src, see this and this

So I think the theory was that someone would be able to do something like

map.on('easyPrint-start', function(ev) {
    // do something in here
});

I think from memory I tested it an it works... but it was along time ago that I wrote it :)

Let me know how you get on
Cheers
Rowan

@adacurro-usgs
Copy link
Author

Thank you I will try this.

@adacurro-usgs
Copy link
Author

Hi @rowanwins it works! However, I need one more event. How do you call if the print is successful?

Thanks again for your help!

@rowanwins
Copy link
Owner

Awesome, perhaps try

map.on('easyPrint-finished', function (ev) {
    // do something in here
});

pretty sure this event is only fired if the print is successful.

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

2 participants