]> git.sesse.net Git - kdenlive/blobdiff - src/mainwindow.cpp
Fix snap button bug: http://www.kdenlive.org:80/mantis/view.php?id=259
[kdenlive] / src / mainwindow.cpp
index 4488872f6c4aad33012704a6c9a8d7881e3ebded..891a391602c3a3eed71ed7811fc9dcaae54cb9ce 100644 (file)
@@ -656,6 +656,7 @@ void MainWindow::setupActions() {
 
     KAction* projectRender = new KAction(KIcon("media-record"), i18n("Render"), this);
     collection->addAction("project_render", projectRender);
+    projectRender->setShortcut(Qt::CTRL + Qt::Key_Return);
     connect(projectRender, SIGNAL(triggered(bool)), this, SLOT(slotRenderProject()));
 
     KAction* monitorPlay = new KAction(KIcon("media-playback-start"), i18n("Play"), this);
@@ -776,39 +777,31 @@ void MainWindow::setupActions() {
     collection->addAction("paste_effects", pasteEffects);
     connect(pasteEffects , SIGNAL(triggered()), this, SLOT(slotPasteEffects()));
 
-    KStandardAction::quit(this, SLOT(queryQuit()),
-                          collection);
+    KStandardAction::close(this, SLOT(closeCurrentDocument()), collection);
 
-    KStandardAction::open(this, SLOT(openFile()),
-                          collection);
+    KStandardAction::quit(this, SLOT(queryQuit()), collection);
 
-    m_saveAction = KStandardAction::save(this, SLOT(saveFile()),
-                                         collection);
+    KStandardAction::open(this, SLOT(openFile()), collection);
 
-    KStandardAction::saveAs(this, SLOT(saveFileAs()),
-                            collection);
+    m_saveAction = KStandardAction::save(this, SLOT(saveFile()), collection);
 
-    KStandardAction::openNew(this, SLOT(newFile()),
-                             collection);
+    KStandardAction::saveAs(this, SLOT(saveFileAs()), collection);
 
-    KStandardAction::preferences(this, SLOT(slotPreferences()),
-                                 collection);
+    KStandardAction::openNew(this, SLOT(newFile()), collection);
 
-    KStandardAction::configureNotifications(this , SLOT(configureNotifications()) , collection);
+    KStandardAction::preferences(this, SLOT(slotPreferences()), collection);
 
-    KStandardAction::copy(this, SLOT(slotCopy()),
-                          collection);
+    KStandardAction::configureNotifications(this , SLOT(configureNotifications()), collection);
 
-    KStandardAction::paste(this, SLOT(slotPaste()),
-                           collection);
+    KStandardAction::copy(this, SLOT(slotCopy()), collection);
 
-    KAction *undo = KStandardAction::undo(m_commandStack, SLOT(undo()),
-                                          collection);
+    KStandardAction::paste(this, SLOT(slotPaste()), collection);
+
+    KAction *undo = KStandardAction::undo(m_commandStack, SLOT(undo()), collection);
     undo->setEnabled(false);
     connect(m_commandStack, SIGNAL(canUndoChanged(bool)), undo, SLOT(setEnabled(bool)));
 
-    KAction *redo = KStandardAction::redo(m_commandStack, SLOT(redo()),
-                                          collection);
+    KAction *redo = KStandardAction::redo(m_commandStack, SLOT(redo()), collection);
     redo->setEnabled(false);
     connect(m_commandStack, SIGNAL(canRedoChanged(bool)), redo, SLOT(setEnabled(bool)));
 
@@ -853,13 +846,12 @@ void MainWindow::newFile(bool showProjectSettings) {
     KUrl projectFolder;
     QPoint projectTracks(3, 2);
     if (!showProjectSettings && m_timelineArea->count() == 0) {
-       if (!KdenliveSettings::activatetabs()) closeCurrentDocument();
-       profileName = KdenliveSettings::default_profile();
-    }
-    else {
+        if (!KdenliveSettings::activatetabs()) closeCurrentDocument();
+        profileName = KdenliveSettings::default_profile();
+    } else {
         ProjectSettings *w = new ProjectSettings;
         if (w->exec() != QDialog::Accepted) return;
-       if (!KdenliveSettings::activatetabs()) closeCurrentDocument();
+        if (!KdenliveSettings::activatetabs()) closeCurrentDocument();
         profileName = w->selectedProfile();
         projectFolder = w->selectedFolder();
         projectTracks = w->tracks();
@@ -1384,7 +1376,7 @@ void MainWindow::slotSwitchMarkersComments() {
 
 void MainWindow::slotSwitchSnap() {
     KdenliveSettings::setSnaptopoints(!KdenliveSettings::snaptopoints());
-    m_buttonShowMarkers->setChecked(KdenliveSettings::snaptopoints());
+    m_buttonSnap->setChecked(KdenliveSettings::snaptopoints());
 }