QML scrollbar: Timeout the scroll timer as soon as the arrow is pressed. This avoids getting no reaction when arrow is clicked very quickly.
This commit is contained in:
parent
021ca8c08a
commit
11991bdd14
@ -139,11 +139,13 @@ PlasmaCore.FrameSvgItem {
|
|||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
enabled: scrollbar.enabled
|
enabled: scrollbar.enabled
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
||||||
Timer {
|
Timer {
|
||||||
id: leftTimer
|
id: leftTimer
|
||||||
interval: scrollbar.scrollButtonInterval;
|
interval: scrollbar.scrollButtonInterval;
|
||||||
running: parent.pressed
|
running: parent.pressed
|
||||||
repeat: true
|
repeat: true
|
||||||
|
triggeredOnStart: true
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
background.forceActiveFocus()
|
background.forceActiveFocus()
|
||||||
if (inverted) {
|
if (inverted) {
|
||||||
@ -187,11 +189,13 @@ PlasmaCore.FrameSvgItem {
|
|||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
enabled: scrollbar.enabled
|
enabled: scrollbar.enabled
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
||||||
Timer {
|
Timer {
|
||||||
id: rightTimer
|
id: rightTimer
|
||||||
interval: scrollbar.scrollButtonInterval;
|
interval: scrollbar.scrollButtonInterval;
|
||||||
running: parent.pressed;
|
running: parent.pressed;
|
||||||
repeat: true
|
repeat: true
|
||||||
|
triggeredOnStart: true
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
background.forceActiveFocus();
|
background.forceActiveFocus();
|
||||||
if (inverted)
|
if (inverted)
|
||||||
|
Loading…
Reference in New Issue
Block a user