Commit 196eb87f authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Move audio scrub confif from Kdenlive Settings to Monitor menu, and make it...

Move audio scrub confif from Kdenlive Settings to Monitor menu, and make it possible with a shortcut.
Fixes #1358
parent c1a06607
<!DOCTYPE kpartgui SYSTEM "kpartgui.dtd">
<kpartgui name="kdenlive" version="207" translationDomain="kdenlive">
<kpartgui name="kdenlive" version="208" translationDomain="kdenlive">
<MenuBar>
<Menu name="file" >
<Action name="file_save"/>
......@@ -241,6 +241,7 @@
<Action name="mlt_interpolation" />
<Action name="mlt_gamma" />
<Action name="mlt_realtime" />
<Action name="mlt_scrub" />
<Action name="mlt_mute" />
</Menu>
<Action name="switch_monitor" />
......
......@@ -686,6 +686,8 @@ void Monitor::setupMenu(QMenu *goMenu, QMenu *overlayMenu, QAction *playZone, QA
m_contextMenu->addMenu(overlayMenu);
}
m_configMenuAction->addAction(m_monitorManager->getAction("mlt_scrub"));
QAction *switchAudioMonitor = new QAction(i18n("Show Audio Levels"), this);
connect(switchAudioMonitor, &QAction::triggered, this, &Monitor::slotSwitchAudioMonitor);
m_configMenuAction->addAction(switchAudioMonitor);
......
......@@ -589,12 +589,20 @@ void MonitorManager::setupActions()
pCore->window()->addAction(QStringLiteral("mlt_interpolation"), interpol);
pCore->window()->actionCollection()->setShortcutsConfigurable(interpol, false);
QAction *progressive = new QAction(QIcon::fromTheme(QString()), i18n("Progressive playback"), this);
QAction *progressive = new QAction(i18n("Progressive playback"), this);
connect(progressive, &QAction::triggered, this, &MonitorManager::slotProgressivePlay);
pCore->window()->addAction(QStringLiteral("mlt_progressive"), progressive);
progressive->setCheckable(true);
progressive->setChecked(KdenliveSettings::monitor_progressive());
QAction *audioScrub = new QAction(i18n("Audio Scrubbing"), this);
connect(audioScrub, &QAction::triggered, this, [&] (bool enable) {
KdenliveSettings::setAudio_scrub(enable);
});
pCore->window()->addAction(QStringLiteral("mlt_scrub"), audioScrub);
audioScrub->setCheckable(true);
audioScrub->setChecked(KdenliveSettings::audio_scrub());
m_muteAction = new KDualAction(i18n("Mute Monitor"), i18n("Unmute Monitor"), this);
m_muteAction->setActiveIcon(QIcon::fromTheme(QStringLiteral("audio-volume-medium")));
m_muteAction->setInactiveIcon(QIcon::fromTheme(QStringLiteral("audio-volume-muted")));
......
......@@ -6,11 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>611</width>
<height>506</height>
<width>410</width>
<height>382</height>
</rect>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<item row="2" column="2" colspan="4">
<widget class="QComboBox" name="kcfg_audio_backend"/>
</item>
<item row="0" column="0" colspan="6">
<widget class="QLabel" name="label_2">
<property name="text">
......@@ -21,106 +24,72 @@
</property>
</widget>
</item>
<item row="4" column="0" colspan="6">
<widget class="QGroupBox" name="group_sdl">
<property name="title">
<string/>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="textLabel1_2">
<property name="sizePolicy">
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Audio driver:</string>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="kcfg_audio_driver"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="textLabel1">
<property name="text">
<string>Audio device:</string>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="kcfg_audio_device"/>
</item>
</layout>
</widget>
</item>
<item row="6" column="0">
<widget class="QLabel" name="label_6">
<item row="9" column="5">
<widget class="QToolButton" name="reload_blackmagic">
<property name="text">
<string>Monitor for fullscreen output:</string>
<string>...</string>
</property>
</widget>
</item>
<item row="8" column="0" colspan="6">
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Horizontal</enum>
<property name="icon">
<iconset theme="view-refresh">
<normaloff>.</normaloff>.</iconset>
</property>
</widget>
</item>
<item row="10" column="0">
<widget class="QLabel" name="label_5">
<item row="6" column="0" colspan="2">
<widget class="QLabel" name="label">
<property name="text">
<string>Output device:</string>
<string>Monitor background color:</string>
</property>
</widget>
</item>
<item row="6" column="2" colspan="4">
<widget class="QComboBox" name="fullscreen_monitor"/>
</item>
<item row="3" column="0" colspan="2">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Audio Backend</string>
<widget class="KColorButton" name="kcfg_window_background">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="defaultColor">
<color>
<red>180</red>
<green>180</green>
<blue>180</blue>
</color>
</property>
</widget>
</item>
<item row="2" column="3" colspan="3">
<widget class="QComboBox" name="kcfg_audio_backend"/>
</item>
<item row="1" column="0" colspan="6">
<widget class="QCheckBox" name="kcfg_gpu_accel">
<item row="9" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Use GPU processing (Movit library) - restart Kdenlive to apply</string>
<string>Output device:</string>
</property>
</widget>
</item>
<item row="5" column="0" colspan="2">
<widget class="QLabel" name="label_3">
<item row="8" column="0" colspan="4">
<widget class="QCheckBox" name="kcfg_external_display">
<property name="text">
<string>Preview volume:</string>
<string>Use external display (Blackmagic card)</string>
</property>
</widget>
</item>
<item row="10" column="5">
<widget class="QToolButton" name="reload_blackmagic">
<property name="text">
<string>...</string>
<item row="5" column="2" colspan="4">
<widget class="QComboBox" name="fullscreen_monitor"/>
</item>
<item row="9" column="1" colspan="4">
<widget class="QComboBox" name="kcfg_blackmagic_output_device">
<property name="enabled">
<bool>true</bool>
</property>
<property name="icon">
<iconset theme="view-refresh"/>
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="11" column="4">
<item row="10" column="4">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
......@@ -133,41 +102,83 @@
</property>
</spacer>
</item>
<item row="2" column="0" colspan="6">
<widget class="QCheckBox" name="kcfg_audio_scrub">
<item row="7" column="0" colspan="6">
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item row="2" column="0" colspan="2">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Enable audio scrubbing:</string>
<string>Audio Backend:</string>
</property>
</widget>
</item>
<item row="9" column="0" colspan="4">
<widget class="QCheckBox" name="kcfg_external_display">
<item row="1" column="0" colspan="6">
<widget class="QCheckBox" name="kcfg_gpu_accel">
<property name="text">
<string>Use external display (Blackmagic card)</string>
<string>Use GPU processing (Movit library) - restart Kdenlive to apply</string>
</property>
</widget>
</item>
<item row="7" column="0" colspan="2">
<widget class="QLabel" name="label">
<item row="4" column="0" colspan="2">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Monitor background color:</string>
<string>Preview volume:</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="4">
<widget class="QComboBox" name="kcfg_blackmagic_output_device">
<property name="enabled">
<bool>true</bool>
<item row="3" column="0" colspan="6">
<widget class="QGroupBox" name="group_sdl">
<property name="title">
<string/>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="textLabel1_2">
<property name="sizePolicy">
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Audio driver:</string>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="kcfg_audio_driver"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="textLabel1">
<property name="text">
<string>Audio device:</string>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="kcfg_audio_device"/>
</item>
</layout>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Monitor for fullscreen output:</string>
</property>
</widget>
</item>
<item row="5" column="2" colspan="4">
<item row="4" column="2" colspan="4">
<widget class="QSpinBox" name="kcfg_volume">
<property name="suffix">
<string>%</string>
......@@ -180,23 +191,6 @@
</property>
</widget>
</item>
<item row="7" column="2" colspan="4">
<widget class="KColorButton" name="kcfg_window_background">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="defaultColor">
<color>
<red>180</red>
<green>180</green>
<blue>180</blue>
</color>
</property>
</widget>
</item>
</layout>
</widget>
<customwidgets>
......
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