X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmainwindow.cpp;h=e8126e0755542159d5baa820280f351033d13f91;hb=ba471399b55c3b761ccc7aa5008c25bd43cfe90b;hp=2936b538703ba00cc22e593364ddfd8481e86d51;hpb=76c9abb930245e56533fb0282b919deb33a6d126;p=kdenlive diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 2936b538..e8126e07 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1402,6 +1402,11 @@ void MainWindow::setupActions() collection.addAction("delete_timeline_clip", deleteItem); connect(deleteItem, SIGNAL(triggered(bool)), this, SLOT(slotDeleteItem())); + KAction* alignPlayhead = new KAction(i18n("Align Playhead to Mouse Position"), this); + alignPlayhead->setShortcut(Qt::Key_P); + collection.addAction("align_playhead", alignPlayhead); + connect(alignPlayhead, SIGNAL(triggered(bool)), this, SLOT(slotAlignPlayheadToMousePos())); + /*KAction* editTimelineClipSpeed = new KAction(i18n("Change Clip Speed"), this); collection.addAction("change_clip_speed", editTimelineClipSpeed); editTimelineClipSpeed->setData("change_speed"); @@ -4581,6 +4586,10 @@ void MainWindow::slotProcessImportKeyframes(GRAPHICSRECTITEM type, const QString } } +void MainWindow::slotAlignPlayheadToMousePos() +{ + m_activeTimeline->projectView()->slotAlignPlayheadToMousePos(); +} #include "mainwindow.moc"