added paste insert

This commit is contained in:
itsmattkc
2018-11-17 09:46:16 +11:00
parent 07bff6014a
commit 3902a7df54
6 changed files with 62 additions and 25 deletions
+5 -2
View File
@@ -398,10 +398,13 @@ void insert_clips(ComboAction* ca) {
if (g.clip >= 0) {
ignore_clips.append(sequence->clips.at(g.clip));
} else {
// don't try to close old gap if importing
ripple_old_point = false;
}
}
panel_timeline->split_cache.clear();
for (int i=0;i<sequence->clips.size();i++) {
Clip* c = sequence->clips.at(i);
if (c != NULL) {
@@ -417,6 +420,8 @@ void insert_clips(ComboAction* ca) {
if (c->timeline_in < earliest_new_point && c->timeline_out > earliest_new_point) {
panel_timeline->split_clip_and_relink(ca, i, earliest_new_point, true);
}
// determine if we should close the gap the old clips left behind
if (ripple_old_point
&& !((c->timeline_in < earliest_old_point && c->timeline_out <= earliest_old_point) || (c->timeline_in >= latest_old_point && c->timeline_out > latest_old_point))
&& !ignore_clips.contains(c)) {
@@ -426,8 +431,6 @@ void insert_clips(ComboAction* ca) {
}
}
panel_timeline->split_cache.clear();
long ripple_length = (latest_new_point - earliest_new_point);
RippleCommand* rc = new RippleCommand(sequence, earliest_new_point, ripple_length);