Fix regression breaking timeline resize

parent a42b335f
Pipeline #7189 passed with stage
in 14 minutes and 36 seconds
......@@ -242,7 +242,7 @@ Rectangle {
hoverEnabled: root.activeTool === 0
cursorShape: (trimInMouseArea.drag.active || trimOutMouseArea.drag.active)? Qt.SizeHorCursor : dragProxyArea.cursorShape
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
if (mouse.button == Qt.RightButton) {
if (timeline.selection.indexOf(clipRoot.clipId) == -1) {
controller.requestAddToSelection(clipRoot.clipId, true)
......@@ -647,7 +647,7 @@ Rectangle {
}
}
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
startX = Math.round(parent.x / timeScale)
startFadeIn = clipRoot.fadeIn
parent.anchors.left = undefined
......@@ -657,7 +657,7 @@ Rectangle {
// parentTrack.clipSelected(clipRoot, parentTrack) TODO
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
fadeInTriangle.opacity = 0.3
parent.opacity = 0
if (fadeInTriangle.width > parent.radius)
......@@ -746,7 +746,7 @@ Rectangle {
}
drag.smoothed: false
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
startX = Math.round(parent.x / timeScale)
startFadeOut = clipRoot.fadeOut
parent.anchors.right = undefined
......@@ -757,7 +757,7 @@ Rectangle {
onReleased: {
fadeOutCanvas.opacity = 0.3
parent.opacity = 0
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
if (fadeOutCanvas.width > parent.radius)
parent.anchors.horizontalCenter = fadeOutCanvas.left
else
......@@ -842,7 +842,7 @@ Rectangle {
property bool sizeChanged: false
cursorShape: (containsMouse ? Qt.SizeHorCursor : Qt.ClosedHandCursor);
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
clipRoot.originalX = clipRoot.x
clipRoot.originalDuration = clipDuration
parent.anchors.left = undefined
......@@ -854,7 +854,7 @@ Rectangle {
parent.opacity = 0
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
parent.anchors.left = clipRoot.left
if (sizeChanged) {
clipRoot.trimmedIn(clipRoot, shiftTrim, controlTrim)
......@@ -925,7 +925,7 @@ Rectangle {
drag.smoothed: false
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
clipRoot.originalDuration = clipDuration
parent.anchors.right = undefined
shiftTrim = mouse.modifiers & Qt.ShiftModifier
......@@ -936,7 +936,7 @@ Rectangle {
parent.opacity = 0
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
parent.anchors.right = clipRoot.right
if (sizeChanged) {
clipRoot.trimmedOut(clipRoot, shiftTrim, controlTrim)
......
......@@ -146,7 +146,7 @@ Item {
cursorShape: (trimInMouseArea.drag.active || trimOutMouseArea.drag.active)? Qt.SizeHorCursor : dragProxyArea.cursorShape
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
compositionRoot.forceActiveFocus();
if (mouse.button == Qt.RightButton) {
if (timeline.selection.indexOf(compositionRoot.clipId) == -1) {
......@@ -159,7 +159,7 @@ Item {
}
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
}
onEntered: {
var itemPos = mapToItem(tracksContainerArea, 0, 0, width, height)
......@@ -285,13 +285,13 @@ Item {
drag.smoothed: false
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
compositionRoot.originalX = compositionRoot.x
compositionRoot.originalDuration = clipDuration
parent.anchors.left = undefined
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
parent.anchors.left = displayRect.left
compositionRoot.trimmedIn(compositionRoot)
parent.opacity = 0
......@@ -335,12 +335,12 @@ Item {
drag.smoothed: false
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
compositionRoot.originalDuration = clipDuration
parent.anchors.right = undefined
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
parent.anchors.right = displayRect.right
compositionRoot.trimmedOut(compositionRoot)
}
......
......@@ -120,7 +120,7 @@ Rectangle
drag.smoothed: false
drag.axis: Drag.XAxis
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
dragPos = -1
var newPos = Math.round(parent.x / timeScale) + inPoint
if (frame != inPoint && newPos != frame) {
......@@ -178,7 +178,7 @@ Rectangle
keyframeContainer.focus = true
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
var newPos = frame == inPoint ? inPoint : Math.round((keyframe.x + parent.x + root.baseUnit / 2) / timeScale) + inPoint
if (newPos == frame && keyframe.value == keyframe.height - parent.y - root.baseUnit / 2) {
var pos = masterObject.modelStart + frame - inPoint
......
......@@ -466,12 +466,12 @@ Rectangle {
drag.smoothed: false
onPressed: {
root.stopScrolling = true
root.autoScrolling = false
startY = mapToItem(null, x, y).y
originalY = trackHeadRoot.height // reusing originalX to accumulate delta for bubble help
}
onReleased: {
root.stopScrolling = false
root.autoScrolling = timeline.autoScroll
if (!trimInMouseArea.containsMouse) {
parent.opacity = 0
}
......
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