Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Scott Petrovic
kdenlive
Commits
5c4dbf15
Commit
5c4dbf15
authored
Apr 03, 2019
by
Jean-Baptiste Mardelle
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Vertical scroll in timeline with Shift + Wheel
parent
81dc0acc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
src/timeline2/view/qml/timeline.qml
src/timeline2/view/qml/timeline.qml
+7
-0
No files found.
src/timeline2/view/qml/timeline.qml
View file @
5c4dbf15
...
...
@@ -67,18 +67,25 @@ Rectangle {
function
zoomByWheel
(
wheel
)
{
if
(
wheel
.
modifiers
&
Qt
.
AltModifier
)
{
// Seek to next snap
if
(
wheel
.
angleDelta
.
x
>
0
)
{
timeline
.
triggerAction
(
'
monitor_seek_snap_backward
'
)
}
else
{
timeline
.
triggerAction
(
'
monitor_seek_snap_forward
'
)
}
}
else
if
(
wheel
.
modifiers
&
Qt
.
ControlModifier
)
{
// Zoom
if
(
wheel
.
angleDelta
.
y
>
0
)
{
root
.
zoomIn
(
true
);
}
else
{
root
.
zoomOut
(
true
);
}
}
else
if
(
wheel
.
modifiers
&
Qt
.
ShiftModifier
)
{
// Vertical scroll
var
newScroll
=
Math
.
min
(
scrollView
.
flickableItem
.
contentY
-
wheel
.
angleDelta
.
y
,
trackHeaders
.
height
-
tracksArea
.
height
+
scrollView
.
__horizontalScrollBar
.
height
+
cornerstone
.
height
)
scrollView
.
flickableItem
.
contentY
=
Math
.
max
(
newScroll
,
0
)
}
else
{
// Horizontal scroll
var
newScroll
=
Math
.
min
(
scrollView
.
flickableItem
.
contentX
-
wheel
.
angleDelta
.
y
,
timeline
.
fullDuration
*
root
.
timeScale
-
(
scrollView
.
width
-
scrollView
.
__verticalScrollBar
.
width
))
scrollView
.
flickableItem
.
contentX
=
Math
.
max
(
newScroll
,
0
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment