diff --git a/mscore/musescore.cpp b/mscore/musescore.cpp index 95f67f55d6e8..b411c48fe5d5 100644 --- a/mscore/musescore.cpp +++ b/mscore/musescore.cpp @@ -2051,6 +2051,7 @@ void MuseScore::showPlayPanel(bool visible) return; playPanel = new PlayPanel(this); connect(playPanel, SIGNAL(gainChange(float)), synti, SLOT(setGain(float))); + connect(playPanel, SIGNAL(metronomeGainChanged(float)), seq, SLOT(setMetronomeGain(float))); connect(playPanel, SIGNAL(relTempoChanged(double)),seq, SLOT(setRelTempo(double))); connect(playPanel, SIGNAL(posChange(int)), seq, SLOT(seek(int))); connect(playPanel, SIGNAL(closed(bool)), playId, SLOT(setChecked(bool))); diff --git a/mscore/playpanel.cpp b/mscore/playpanel.cpp index 18c67046865b..a24cb181f449 100644 --- a/mscore/playpanel.cpp +++ b/mscore/playpanel.cpp @@ -61,7 +61,10 @@ PlayPanel::PlayPanel(QWidget* parent) tempoSlider->setDclickValue2(100.0); tempoSlider->setUseActualValue(true); + mgainSlider->setValue(seq->metronomeGain()); + connect(volumeSlider, SIGNAL(valueChanged(double,int)), SLOT(volumeChanged(double,int))); + connect(mgainSlider, SIGNAL(valueChanged(double,int)), SLOT(metronomeGainChanged(double,int))); connect(posSlider, SIGNAL(sliderMoved(int)), SLOT(setPos(int))); connect(tempoSlider, SIGNAL(valueChanged(double,int)), SLOT(relTempoChanged(double,int))); connect(tempoSlider, SIGNAL(sliderPressed(int)), SLOT(tempoSliderPressed(int))); @@ -244,6 +247,15 @@ void PlayPanel::volumeChanged(double val, int) emit gainChange(val); } +//--------------------------------------------------------- +// metronomeGainChanged +//--------------------------------------------------------- + +void PlayPanel::metronomeGainChanged(double val, int) + { + emit metronomeGainChanged(val); + } + //--------------------------------------------------------- // setPos //--------------------------------------------------------- diff --git a/mscore/playpanel.h b/mscore/playpanel.h index 7d2b1c1d7b59..983398b15d1c 100644 --- a/mscore/playpanel.h +++ b/mscore/playpanel.h @@ -49,6 +49,7 @@ class PlayPanel : public QWidget, private Ui::PlayPanelBase { private slots: void volumeChanged(double,int); + void metronomeGainChanged(double val, int); void relTempoChanged(double,int); void relTempoChanged(); void tempoSliderReleased(int); @@ -60,6 +61,7 @@ class PlayPanel : public QWidget, private Ui::PlayPanelBase { signals: void relTempoChanged(double); + void metronomeGainChanged(float); void posChange(int); void gainChange(float); void closed(bool); diff --git a/mscore/playpanel.ui b/mscore/playpanel.ui index 76028933aee6..c8034e695bd9 100644 --- a/mscore/playpanel.ui +++ b/mscore/playpanel.ui @@ -6,7 +6,7 @@ 0 0 - 380 + 389 293 @@ -153,7 +153,7 @@ - + 1 @@ -219,32 +219,6 @@ - - - - - - - - - - :/data/icons/media-playback-countin.svg:/data/icons/media-playback-countin.svg - - - - - - - - - - - :/data/icons/media-playback-metronome.svg:/data/icons/media-playback-metronome.svg - - - - - @@ -351,7 +325,41 @@ 6 - + + + + + 0 + 0 + + + + + + + Actual tempo in quarter notes per minute + + + QFrame::StyledPanel + + + 2 + + + 2 + + + 120 BPM + + + Qt::AlignCenter + + + Qt::NoTextInteraction + + + + @@ -391,29 +399,7 @@ - - - - - 0 - 0 - - - - Qt::TabFocus - - - Master volume - - - Master Volume - - - Use up and down arrows to change value - - - - + Volume @@ -423,51 +409,59 @@ - - - - - 0 - 0 - - - - - - - Actual tempo in quarter notes per minute - - - QFrame::StyledPanel - - - 2 - - - 2 - - - 120 BPM - - - Qt::AlignCenter - - - Qt::NoTextInteraction - - - - - - Tempo - - - Qt::AlignCenter - - + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + + + + + :/data/icons/media-playback-metronome.svg:/data/icons/media-playback-metronome.svg + + + + + + + + + + + :/data/icons/media-playback-countin.svg:/data/icons/media-playback-countin.svg + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + - + Relative tempo to 120 beats per minute @@ -501,6 +495,60 @@ + + + + Tempo + + + Qt::AlignCenter + + + + + + + + 0 + 0 + + + + Qt::TabFocus + + + Metronome volume + + + Metronome Volume + + + Use up and down arrows to change value + + + + + + + + 0 + 0 + + + + Qt::TabFocus + + + Master volume + + + Master Volume + + + Use up and down arrows to change value + + + @@ -521,8 +569,6 @@ posSlider rewindButton playButton - countInButton - metronomeButton loopInButton loopButton loopOutButton diff --git a/mscore/synthcontrol.cpp b/mscore/synthcontrol.cpp index 6f50f12d8ebe..bc2bd7d69263 100644 --- a/mscore/synthcontrol.cpp +++ b/mscore/synthcontrol.cpp @@ -76,8 +76,6 @@ SynthControl::SynthControl(QWidget* parent) } } readSettings(); - metronome->setDefaultAction(getAction("metronome")); - mgain->setValue(seq->metronomeGain()); updateGui(); @@ -89,7 +87,6 @@ SynthControl::SynthControl(QWidget* parent) connect(effectA, SIGNAL(currentIndexChanged(int)), SLOT(effectAChanged(int))); connect(effectB, SIGNAL(currentIndexChanged(int)), SLOT(effectBChanged(int))); connect(gain, SIGNAL(valueChanged(double,int)), SLOT(gainChanged(double,int))); - connect(mgain, SIGNAL(valueChanged(double,int)), SLOT(metronomeGainChanged(double,int))); connect(masterTuning, SIGNAL(valueChanged(double)), SLOT(masterTuningChanged(double))); connect(changeTuningButton, SIGNAL(clicked()), SLOT(changeMasterTuning())); connect(loadButton, SIGNAL(clicked()), SLOT(loadButtonClicked())); @@ -165,7 +162,6 @@ void MuseScore::showSynthControl(bool val) connect(synthControl, SIGNAL(closed(bool)), a, SLOT(setChecked(bool))); if (mixer) connect(synthControl, SIGNAL(soundFontChanged()), mixer, SLOT(patchListChanged())); - connect(synthControl, SIGNAL(metronomeGainChanged(float)), seq, SLOT(setMetronomeGain(float))); } synthControl->setVisible(val); } @@ -179,15 +175,6 @@ void SynthControl::gainChanged(double val, int) emit gainChanged(val); } -//--------------------------------------------------------- -// metronomeGainChanged -//--------------------------------------------------------- - -void SynthControl::metronomeGainChanged(double val, int) - { - emit metronomeGainChanged(val); - } - //--------------------------------------------------------- // masterTuningChanged //--------------------------------------------------------- diff --git a/mscore/synthcontrol.h b/mscore/synthcontrol.h index cbfdcb5e1750..7d1caf628e2f 100644 --- a/mscore/synthcontrol.h +++ b/mscore/synthcontrol.h @@ -47,7 +47,6 @@ class SynthControl : public QWidget, Ui::SynthControl { private slots: void gainChanged(double, int); - void metronomeGainChanged(double val, int); void masterTuningChanged(double); void changeMasterTuning(); void effectAChanged(int); @@ -60,7 +59,6 @@ class SynthControl : public QWidget, Ui::SynthControl { signals: void gainChanged(float); - void metronomeGainChanged(float); void soundFontChanged(); void closed(bool); diff --git a/mscore/synthcontrol.ui b/mscore/synthcontrol.ui index 7c066b6ce1dc..789e00f9796e 100644 --- a/mscore/synthcontrol.ui +++ b/mscore/synthcontrol.ui @@ -10,7 +10,7 @@ 0 0 602 - 281 + 407 @@ -19,7 +19,7 @@ Synthesizer - + 10 @@ -89,10 +89,10 @@ - + - + Qt::TabFocus @@ -105,7 +105,7 @@ Use up and down arrows to modify - + 2 @@ -128,28 +128,6 @@ - - - - - 0 - 0 - - - - Qt::TabFocus - - - Metronome gain - - - Use up and down arrows to modify - - - true - - - @@ -324,13 +302,6 @@ - - - - - - - @@ -356,8 +327,6 @@ effectB masterTuning changeTuningButton - metronome - mgain gain saveButton loadButton