Commit a5be0149 authored by Kezi Olio's avatar Kezi Olio Committed by Oliver Sander
Browse files

Restore mouse drag scrolling, so it starts immediately

QScroller uses a minimum drag distance before drag scrolling starts by default.
This sets the minimum distance to 0.0, to restore the original behavior of the Browse tool.

BUG: 420842
parent c54c38f7
Pipeline #34371 failed with stage
in 84 minutes and 44 seconds
......@@ -421,6 +421,7 @@ PageView::PageView(QWidget *parent, Okular::Document *document)
prop.setScrollMetric(QScrollerProperties::MaximumVelocity, 1);
prop.setScrollMetric(QScrollerProperties::HorizontalOvershootPolicy, QScrollerProperties::OvershootAlwaysOff);
prop.setScrollMetric(QScrollerProperties::VerticalOvershootPolicy, QScrollerProperties::OvershootAlwaysOff);
prop.setScrollMetric(QScrollerProperties::DragStartDistance, 0.0);
d->scroller->setScrollerProperties(prop);
connect(d->scroller, &QScroller::stateChanged, this, &PageView::slotRequestVisiblePixmaps);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment