Improve experience when using mouse clicks to zoom
ClosedPublic

Authored by rkflx on Jul 13 2018, 10:33 PM.

Details

Summary

Gwenview allows to Ctrl-click to zoom in, and
Ctrl-right-click zooms out. However, when clicking fast only every
other click resulted in a zooming action, making the experience feel
slow and cumbersome.

The cause for this is that fast clicks are detected as double-clicks,
with only the first single-click being delivered to Gwenview.

By also zooming when double-clicking, for fast clicks each and every
click will result in an action, making zooming feel natural again.
Luckily there still won't be any duplicate clicks.

Test Plan

Hold Ctrl, repeatedly press left and right mouse buttons (start
slowly and then increase clicking rate). Zooming should work reliably
now.

Diff Detail

Repository
R260 Gwenview
Branch
double-click-zooming (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 823
Build 836: arc lint + arc unit
rkflx requested review of this revision.Jul 13 2018, 10:33 PM
rkflx created this revision.
ngraham accepted this revision.Jul 13 2018, 10:40 PM
ngraham added a subscriber: ngraham.

Works like a charm, and the code change makes sense. I didn't even know about this feature!

This revision is now accepted and ready to land.Jul 13 2018, 10:40 PM
rkflx updated this revision to Diff 37719.Jul 13 2018, 10:46 PM

Make it shorter by two lines

This revision was automatically updated to reflect the committed changes.