slotEditClipMarker: Use QPointer [krazy 26/37] by Mikko Rapeli

parent 2c13ddcb
......@@ -2919,14 +2919,16 @@ void MainWindow::slotEditClipMarker()
}
CommentedTime marker(pos, oldcomment);
MarkerDialog d(clip, marker, m_activeDocument->timecode(), i18n("Edit Marker"), this);
if (d.exec() == QDialog::Accepted) {
m_activeTimeline->projectView()->slotAddClipMarker(id, d.newMarker().time(), d.newMarker().comment());
if (d.newMarker().time() != pos) {
QPointer<MarkerDialog> d = new MarkerDialog(clip, marker,
m_activeDocument->timecode(), i18n("Edit Marker"), this);
if (d->exec() == QDialog::Accepted) {
m_activeTimeline->projectView()->slotAddClipMarker(id, d->newMarker().time(), d->newMarker().comment());
if (d->newMarker().time() != pos) {
// remove old marker
m_activeTimeline->projectView()->slotAddClipMarker(id, pos, QString());
}
}
delete d;
}
void MainWindow::slotAddMarkerGuideQuickly()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment