also send Start phase on receiving first scroll event

This commit is contained in:
Gregory 2016-12-15 00:06:34 +01:00
parent 816b2969c3
commit 48e3ecf71c

View file

@ -1081,6 +1081,7 @@ impl<Window: WindowMethods> IOCompositor<Window> {
delta: TypedPoint2D<f32, DevicePixel>,
cursor: TypedPoint2D<i32, DevicePixel>) {
let event_phase = match (self.scroll_in_progress, self.in_scroll_transaction) {
(false, None) => ScrollEventPhase::Start,
(false, Some(last_scroll)) if last_scroll.elapsed() > Duration::from_millis(80) =>
ScrollEventPhase::Start,
(_, _) => ScrollEventPhase::Move(self.scroll_in_progress),