If you open the /js/wpsl-gmap.js, then on line 67 you see mapOptions.
You can add the isDraggable var and the draggable param to the code, but before it’s used you have to minify the code ( the wpsl-gmap.min.js is the one loaded on the front-end ).
So copy the code from the wpsl-gmap.js, open http://javascript-minifier.com/, minify the code and past it back in wpsl-gmap.min.js.
I don’t have time to test the code myself at the moment, but let me know if it works. I will look into it myself soon, and if it works then include it in the next update.
Hi there
Sweet, that works perfectly, thank you.
Changed the line to read:
draggable: checkMobileUserAgent() ? false : true,
Thank you!
Mark
Mike
(@thewordpressdude)
Hi Tijimen,
This would be a great addition to the plugin. It would be great to be able to specify the screen resolution for the draggable option to be disabled. So for instance, have a check box to set the draggable option and a field for the maximum screen resolution for the option to be active.
My client wants the map to not be draggable for phones or tablets, so I would want to be able to change the settings to affect those resolutions as well.
Thanks,
Mike
Mike
(@thewordpressdude)
Another question; is there a way to preserve customizations so they are not overwritten with the next release of a plugin update, kind of like with child themes?
Thanks,
Mike