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
5013499c
Commit
5013499c
authored
Feb 19, 2021
by
Julius Künzel
Browse files
Subtitles: fix crash on "select clip" shortcut
Fixes
#941
parent
c5d6d41b
Pipeline
#51486
passed with stage
in 10 minutes and 29 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/timeline2/view/timelinecontroller.cpp
View file @
5013499c
...
...
@@ -288,8 +288,13 @@ int TimelineController::selectedTrack() const
void
TimelineController
::
selectCurrentItem
(
ObjectType
type
,
bool
select
,
bool
addToCurrent
)
{
int
currentClip
=
type
==
ObjectType
::
TimelineClip
?
m_model
->
getClipByPosition
(
m_activeTrack
,
pCore
->
getTimelinePosition
())
:
m_model
->
getCompositionByPosition
(
m_activeTrack
,
pCore
->
getTimelinePosition
());
int
currentClip
=
-
1
;
if
(
type
==
ObjectType
::
TimelineClip
)
{
currentClip
=
m_activeTrack
==
-
2
?
m_model
->
getSubtitleByPosition
(
pCore
->
getTimelinePosition
())
:
m_model
->
getClipByPosition
(
m_activeTrack
,
pCore
->
getTimelinePosition
());
}
else
{
currentClip
=
m_model
->
getCompositionByPosition
(
m_activeTrack
,
pCore
->
getTimelinePosition
());
}
if
(
currentClip
==
-
1
)
{
pCore
->
displayMessage
(
i18n
(
"No item under timeline cursor in active track"
),
ErrorMessage
,
500
);
return
;
...
...
Write
Preview
Supports
Markdown
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