Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Multimedia
Kdenlive
Commits
f4cb0436
Commit
f4cb0436
authored
Sep 26, 2021
by
Julius Künzel
Browse files
Improve cursor shape for keyframe view in timeline
Fixes
#1203
parent
8d14944b
Pipeline
#82847
passed with stage
in 9 minutes and 21 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/timeline2/view/qml/KeyframeView.qml
View file @
f4cb0436
...
@@ -165,16 +165,18 @@ Rectangle
...
@@ -165,16 +165,18 @@ Rectangle
radius
:
width
/
2
radius
:
width
/
2
color
:
keyframeContainer
.
activeFrame
==
keyframe
.
frame
?
'
red
'
:
kf1MouseArea
.
containsMouse
||
kf1MouseArea
.
pressed
?
root
.
textColor
:
root
.
videoColor
color
:
keyframeContainer
.
activeFrame
==
keyframe
.
frame
?
'
red
'
:
kf1MouseArea
.
containsMouse
||
kf1MouseArea
.
pressed
?
root
.
textColor
:
root
.
videoColor
border.color
:
kf1MouseArea
.
containsMouse
||
kf1MouseArea
.
pressed
?
activePalette
.
highlight
:
root
.
textColor
border.color
:
kf1MouseArea
.
containsMouse
||
kf1MouseArea
.
pressed
?
activePalette
.
highlight
:
root
.
textColor
MouseArea
{
MouseArea
{
id
:
kf1MouseArea
id
:
kf1MouseArea
anchors.fill
:
parent
anchors.fill
:
parent
hoverEnabled
:
true
hoverEnabled
:
true
cursorShape
:
Qt
.
PointingHandCursor
cursorShape
:
shiftPressed
?
Qt
.
SizeVerCursor
:
Qt
.
PointingHandCursor
drag.target
:
parent
drag.target
:
parent
drag.smoothed
:
false
drag.smoothed
:
false
drag.threshold
:
1
drag.threshold
:
1
property
string
movingVal
:
kfrModel
.
realValue
(
model
.
normalizedValue
)
property
string
movingVal
:
kfrModel
.
realValue
(
model
.
normalizedValue
)
property
double
newVal
:
NaN
property
double
newVal
:
NaN
property
bool
shiftPressed
:
false
onPressed
:
{
onPressed
:
{
drag
.
axis
=
(
mouse
.
modifiers
&
Qt
.
ShiftModifier
)
?
Drag
.
YAxis
:
Drag
.
XAndYAxis
drag
.
axis
=
(
mouse
.
modifiers
&
Qt
.
ShiftModifier
)
?
Drag
.
YAxis
:
Drag
.
XAndYAxis
}
}
...
@@ -217,6 +219,7 @@ Rectangle
...
@@ -217,6 +219,7 @@ Rectangle
}
}
}
}
onPositionChanged
:
{
onPositionChanged
:
{
shiftPressed
=
(
mouse
.
modifiers
&
Qt
.
ShiftModifier
)
if
(
mouse
.
buttons
===
Qt
.
LeftButton
)
{
if
(
mouse
.
buttons
===
Qt
.
LeftButton
)
{
if
(
frame
==
inPoint
)
{
if
(
frame
==
inPoint
)
{
parent
.
x
=
-
root
.
baseUnit
/
2
parent
.
x
=
-
root
.
baseUnit
/
2
...
...
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