ScrollViewer and ChangeView - ZoomToFactor


  • I have a ScrollVviewer and inside it a FlipVview

    Using ZoomMode to enabled you can Zoom the content

    I want to add a DoubleTap so the Image inside FlipView goes to Zoom = 0. Then same when change the view to another Image

    This is very easy, but..

    1- Works on the SelectionChange

    2- Didn't work on DoubleTapped

    3- Works with ZoomtoFactor but is almost deprecatd

    private void scrollV_DoubleTapped(object sender, DoubleTappedRoutedEventArgs e)
        scrollV.ChangeView(null, null, 1); // didn't works
        //scrollV.ZoomToFactor(1); // works but deprecated
    private void FlipV_SelectionChanged(object sender, SelectionChangedEventArgs e)
        scrollV.ChangeView(null, null, 1); // works

    Wednesday, January 28, 2015 12:13 AM