Hi,
Just updated to Qt 5.3.2 (from 5.3.1) and have some problems with the scroll wheel behavior. Mouse scrolling on a Slider inside a ScrollView affect both the Slider and the ScrollView at the same time.
This behavior is visible everywhere the event is not accepted. Look like the wheel event now cascade on underlaying widget. But we cannot accept this event with the QtQuick Controls. That would be nice to have a hook to accept the event or a switch to auto accept wheel event. The Slider.qml inside Qt cannot be modified, since it only pass the horizontalDelta or the verticalDelta to the WheelArea onVerticalWheelMoved and onHorizontalWheelMoved. So no event or wheel parameter are there to accept the event :-( Would need to change the API to fix this. Maybe the WheelArea should give the event into parameters just like the MouseArea.
Maybe I am missing something, but I don’t want to put a Mouse Area under each controls just to accept the wheel event and stop it’s propagation. I understand there must be some use case to perform the event that way, but a way to select between cascading or not would be welcome, would be even better if could be done into the Control itself. Here’s a simple example to display the problem:
import QtQuick 2.3
import QtQuick.Controls 1.2
import QtQuick.Controls.Styles 1.2
Rectangle
{
ScrollView
{
width: 300
height: 300
Column
{
Rectangle { width: 500; height: 500; color: “red” }
Slider { }
Rectangle { width: 500; height: 500; color: “blue” }
}
}
}
↧