• Resolved glujaz

    (@glujaz)


    Hello,

    I’m looking for a way to avoid zooming on the map when scrolling if the mouse is on it. As you can see on the site, the map takes quite some space, and there are other info below it.
    Even better, is there a way to have a google like “ctrl+scroll” and “two finger move map” ? That would be so perfect !

    Thanks in advance

    The page I need help with: [log in to see the link]

Viewing 3 replies - 16 through 18 (of 18 total)
  • Plugin Author Stonehenge Creations

    (@duisterdenhaag)

    Desktop scrolling is unchanged. The scroll wheel always zooms the map.
    The only change should be the mobile version. It’s either using one finger to pan OR being able to scroll over the map without zooming. Not both.

    Thread Starter glujaz

    (@glujaz)

    Ok, I May have to clarify what I need again.

    On a computer, when the cursor is on the map, I don’t want it to zoom when using the scroll wheel.

    On a touch screen (like iPhone), I don’t want the map to pan when moving my finger on the map, but to scroll the page instead.

    For now, scrolling on a computer with the cursor on the map still makes zooming, and moving my finger on the map does nothing at all (before the beta, it used to at least pan the map, which I didn’t want anyway)

    Hope it’s clearer now ??

    Plugin Author Stonehenge Creations

    (@duisterdenhaag)

    In version 2.4 I added mobile detection to front-end maps. If viewed on a mobile device, the map should no longer be draggable.

    Swiping with one finger will not work, because the map is actually seen as a sort of iframe by the browser. Two-finger swiping could/should work though.

    Zooming in and out on the map can still be done by using the zoom control buttons or by pinching.

    Please make sure your map does not cover the whole length of a mobile device, leaving room for a user to scroll through your page.

    You can easily achieve this, by adding something like this to your theme’s css stylesheet:
    .em-osm-container{ max-height: 75% !important;}

    That should leave room for scrolling, while still maintaining your default map height if the screen is big enough.

Viewing 3 replies - 16 through 18 (of 18 total)
  • The topic ‘Avoid Zoom Scrolling’ is closed to new replies.