Skip to content

Commit

Permalink
Remove dependency on control key when zooming images
Browse files Browse the repository at this point in the history
  • Loading branch information
Jethro-Alter committed Sep 30, 2019
1 parent dccfc81 commit 7fcbe83
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions QuickLook.Plugin/QuickLook.Plugin.ImageViewer/ImagePanel.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright © 2018 Paddy Xu
// Copyright © 2018 Paddy Xu
//
// This file is part of QuickLook program.
//
Expand Down Expand Up @@ -366,16 +366,6 @@ private void ViewPanel_PreviewMouseWheel(object sender, MouseWheelEventArgs e)
{
e.Handled = true;

if ((Keyboard.Modifiers & ModifierKeys.Control) == 0)
{
// normal scroll
viewPanel.ScrollToVerticalOffset(viewPanel.VerticalOffset - e.Delta);

ImageScrolled?.Invoke(this, e.Delta);

return;
}

// zoom
var newZoom = ZoomFactor + ZoomFactor * e.Delta / 120 * 0.1;

Expand Down

0 comments on commit 7fcbe83

Please sign in to comment.