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
9aed5d6d
Commit
9aed5d6d
authored
Nov 01, 2019
by
Jean-Baptiste Mardelle
Browse files
Add some feedback if an insert operation fails.
CCBUG: 413661
parent
b93ac812
Pipeline
#9818
passed with stage
in 13 minutes and 25 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/kdenlivesettings.kcfg
View file @
9aed5d6d
...
...
@@ -123,17 +123,16 @@
<label>
Default OpenGL backend.
</label>
<default>
0
</default>
</entry>
<entry
name=
"showEffectSearchBar"
type=
"Bool"
>
<label>
Show effect search bar by default.
</label>
<default>
true
</default>
</entry>
<entry
name=
"showCompoSearchBar"
type=
"Bool"
>
<label>
Show composition search bar by default.
</label>
<default>
true
</default>
</entry>
</group>
...
...
src/mainwindow.cpp
View file @
9aed5d6d
...
...
@@ -2485,6 +2485,7 @@ void MainWindow::slotInsertClipInsert()
const
QString
&
binId
=
m_clipMonitor
->
activeClipId
();
if
(
binId
.
isEmpty
())
{
// No clip in monitor
pCore
->
displayMessage
(
i18n
(
"No clip selected in project bin"
),
InformationMessage
);
return
;
}
int
pos
=
getMainTimeline
()
->
controller
()
->
insertZone
(
binId
,
m_clipMonitor
->
getZoneInfo
(),
false
);
...
...
src/timeline2/model/timelinefunctions.cpp
View file @
9aed5d6d
...
...
@@ -353,6 +353,7 @@ bool TimelineFunctions::insertZone(const std::shared_ptr<TimelineItemModel> &tim
}
}
if
(
affectedTracks
.
isEmpty
())
{
pCore
->
displayMessage
(
i18n
(
"Please activate a track by clicking on a track's label"
),
InformationMessage
);
return
false
;
}
result
=
breakAffectedGroups
(
timeline
,
affectedTracks
,
QPoint
(
insertFrame
,
insertFrame
+
(
zone
.
y
()
-
zone
.
x
())),
undo
,
redo
);
...
...
src/timeline2/view/timelinecontroller.cpp
View file @
9aed5d6d
...
...
@@ -1677,6 +1677,9 @@ void TimelineController::extractZone(QPoint zone, bool liftOnly)
}
++
it
;
}
if
(
tracks
.
isEmpty
())
{
pCore
->
displayMessage
(
i18n
(
"Please activate a track for this operation by clicking on its label"
),
InformationMessage
);
}
if
(
m_zone
==
QPoint
())
{
// Use current timeline position and clip zone length
zone
.
setY
(
timelinePosition
()
+
zone
.
y
()
-
zone
.
x
());
...
...
@@ -1740,6 +1743,7 @@ bool TimelineController::insertClipZone(const QString &binId, int tid, int posit
if
(
aTrack
>
-
1
)
{
target_tracks
<<
aTrack
;
}
return
TimelineFunctions
::
insertZone
(
m_model
,
target_tracks
,
binId
,
position
,
QPoint
(
in
,
out
+
1
),
m_model
->
m_editMode
==
TimelineMode
::
OverwriteEdit
,
false
);
}
...
...
@@ -1782,6 +1786,10 @@ int TimelineController::insertZone(const QString &binId, QPoint zone, bool overw
if
(
aTrack
>
-
1
)
{
target_tracks
<<
aTrack
;
}
if
(
target_tracks
.
isEmpty
())
{
pCore
->
displayMessage
(
i18n
(
"Please select a target track by clicking on a track's target zone"
),
InformationMessage
);
return
-
1
;
}
return
TimelineFunctions
::
insertZone
(
m_model
,
target_tracks
,
binId
,
insertPoint
,
sourceZone
,
overwrite
)
?
insertPoint
+
(
sourceZone
.
y
()
-
sourceZone
.
x
())
:
-
1
;
}
...
...
Eugen Mohr
@emohr
·
Nov 01, 2019
Developer
Could you put this commit into 19.08.3 branch as well?
Could you put this commit into 19.08.3 branch as well?
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