X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmainwindow.cpp;h=912faa9d0c9071e6471de4c060329892390f2ced;hb=f7b6e23085b1023c9299572245117517e9e86d36;hp=7ae740d668e6b0d1578445cdcffba4741de425b4;hpb=d43962a423f985c81daef1514f3186f0b71fcc1e;p=kdenlive diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 7ae740d6..912faa9d 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -405,11 +405,8 @@ void MainWindow::loadPlugins() { } void MainWindow::populateMenus(QObject *plugin) { - kDebug() << "// POP MENU"; QMenu *addMenu = static_cast(factory()->container("generators", this)); ClipGenerator *iGenerator = qobject_cast(plugin); - kDebug() << "// POP MENU 2"; - if (addMenu) kDebug() << "// POP MENU 3"; if (iGenerator) addToMenu(plugin, iGenerator->generators(), addMenu, SLOT(generateClip()), NULL); @@ -421,6 +418,7 @@ void MainWindow::addToMenu(QObject *plugin, const QStringList &texts, kDebug() << "// ADD to MENU" << texts; foreach(QString text, texts) { QAction *action = new QAction(text, plugin); + action->setData(text); connect(action, SIGNAL(triggered()), this, member); menu->addAction(action); @@ -441,7 +439,7 @@ void MainWindow::generateClip() { QAction *action = qobject_cast(sender()); ClipGenerator *iGenerator = qobject_cast(action->parent()); - KUrl clipUrl = iGenerator->generatedClip(action->text(), m_activeDocument->projectFolder(), QStringList(), QStringList(), 25, 720, 576); + KUrl clipUrl = iGenerator->generatedClip(action->data().toString(), m_activeDocument->projectFolder(), QStringList(), QStringList(), 25, 720, 576); if (!clipUrl.isEmpty()) { m_projectList->slotAddClip(clipUrl); } @@ -1618,6 +1616,7 @@ void MainWindow::slotPreferences(int page, int option) { KdenliveSettingsDialog* dialog = new KdenliveSettingsDialog(this); connect(dialog, SIGNAL(settingsChanged(const QString&)), this, SLOT(updateConfiguration())); connect(dialog, SIGNAL(doResetProfile()), m_monitorManager, SLOT(slotResetProfiles())); + //connect(dialog, SIGNAL(updatePreviewSettings()), this, SLOT(slotUpdatePreviewSettings())); dialog->show(); if (page != -1) dialog->showPage(page, option); } @@ -1638,6 +1637,12 @@ void MainWindow::updateConfiguration() { } +void MainWindow::slotUpdatePreviewSettings() { + //TODO: perform operation on all open documents + m_activeDocument->clipManager()->updatePreviewSettings(); +} + + void MainWindow::slotSwitchVideoThumbs() { KdenliveSettings::setVideothumbnails(!KdenliveSettings::videothumbnails()); if (m_activeTimeline) {