Skip Navigation

[Resolved] Map wont drag when initiated from a marker

This support ticket is created 6 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 1 reply, has 2 voices.

Last updated by Beda 6 years, 6 months ago.

Author
Posts
#951982

I am trying to:
Get a map to be able to drag (pan) when the first mouse click is on a marker.

Link to a page where the issue can be seen:
Any wp-types maps. e.g. hidden link (password protected currently) or hidden link

I expected to see:
When I click and drag anywhere on the map, it should start panning.

Instead, I got:
Clicking on markers means pan does not work. You have to find some space with no markers to be able to pan. This makes maps with many markers not the easiest to use.

As Google maps does this by default I was hoping I was missing something. If it's not available yet I hope it will be soon.

#952236

Do I understand you correctly that this behavior is from Google Maps - by default?
Because, to me it seems, that Google Maps natively lets you drag even if you hover their Icons.

Now, Toolset allows you a few things more with the Markers (pop up etc) so in certain circumstances we cannot let one thing happen (drag) when you want to do something else (pop)

I found, interestingly, that if you use any non.default Icon (and of course, no hover or popup), even provided by Toolset, then the issue is gone:
[wpv-map-marker map_id='map-2' marker_id='marker-2' marker_icon='//tssupp-2604.mamp/wp-content/plugins/toolset-maps/resources/images/markers/Buildings.png' marker_field='wpcf-toolset-address'][/wpv-map-marker]

This for example lets you hower and drag as you want.
As you will see, the same DIV "gmnoprint" from above now has no such CSS added and does not break the dragging.

What I can do is ask the developers why the default icon acts like this while the not-default acts otherwise, but I suspect this has to do with the scripts loaded by the Map (hence, Google API itself and it's possible customizations as in hidden link)