The following forum(s) have migrated to Microsoft Q&A (Preview): Developing Universal Windows apps!
Visit Microsoft Q&A (Preview) to post new questions.

Learn More

 locked
Disable/control pinch zoom in kiosk app? RRS feed

  • Question

  • I am creating a kiosk application, and I am looking for a way to either disable the pinch-zoom gesture entirely, or be able to reset the zoom level programatically using the JS APIs.  Is this possible? I've done some searching, and I am not seeing anything that lets me disable or reset pinch-zooming on my Microsoft Surface unit.

    What I've already looked at:

    1. Disable `Pinch Zoom` in mouse settings.  All the instructions I've found online are for touch-pads.  The Microsoft Surface Pro 4 unit that I have does not have a Pinch Zoom setting in any of the mouse or touch settings.
    2. Setting meta in the HTML to explicitly disallow zooming:  <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />. This had no effect in the application. I am still able to pinch-zoom the application.
    3. Explicitly set the application to not allow scaling: window.Windows.UI.ViewManagement.ApplicationViewScaling.trySetDisableLayoutScaling(true); This also had no effect in the application. I am still able to pinch-zoom the application.
    4. I have confirmed that setting my application as an Assigned Access app does not automatically disable pinch-zooming.

    Ideally, I'd like a way to reset the zoom level, either by user action or after a certain timeout is reached.  This way I could have some confidence that the next user who uses the kiosk won't be presented a zoomed-in interface from the previous user.

    Am I missing some obvious APIs that give me control over pinch zooming?

    Monday, October 10, 2016 6:35 PM

Answers

  • Found the documentation here:

    https://msdn.microsoft.com/library/windows/apps/hh700412?f=255&MSPPError=-2147217396#Views

    Setting `-ms-content-zooming: none` worked for me.

    Monday, October 10, 2016 9:57 PM

All replies

  • Found the documentation here:

    https://msdn.microsoft.com/library/windows/apps/hh700412?f=255&MSPPError=-2147217396#Views

    Setting `-ms-content-zooming: none` worked for me.

    Monday, October 10, 2016 9:57 PM
  • Hi spacenab,

    Welcome to the Developing Universal Windows apps forum!

    Please read the sticky posts, especially the Guide to posting: subject line tags and Known Issues for Windows 10 SDK and Tools 

    Thanks for sharing your solution with us. You could mark your reply as answer. It would be helpful to other developers who're looking for the same questions' answer.

    Best Regards,

    Xavier Eoro


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Tuesday, October 11, 2016 9:54 AM