Mercurial > hg > svapp
changeset 572:4c1ab4f9e116 3.0-integration
Ah, there already was a mechanism for that (recordDurationChanged()). But in any case we are better off prompting the model to update I think.
author | Chris Cannam |
---|---|
date | Wed, 04 Jan 2017 14:21:24 +0000 |
parents | 5369359351cb |
children | 9fb190c6521b |
files | framework/MainWindowBase.cpp framework/MainWindowBase.h |
diffstat | 2 files changed, 4 insertions(+), 12 deletions(-) [+] |
line wrap: on
line diff
--- a/framework/MainWindowBase.cpp Wed Jan 04 13:23:18 2017 +0000 +++ b/framework/MainWindowBase.cpp Wed Jan 04 14:21:24 2017 +0000 @@ -158,7 +158,6 @@ m_initialDarkBackground(false), m_defaultFfwdRwdStep(2, 0), m_audioRecordMode(RecordCreateAdditionalModel), - m_audioRecordUpdateTimer(this), m_statusLabel(0), m_iconsVisibleInMenus(true), m_menuShortcutMapper(0) @@ -231,17 +230,16 @@ this, SLOT(paneDropAccepted(Pane *, QString))); connect(m_paneStack, SIGNAL(paneDeleteButtonClicked(Pane *)), this, SLOT(paneDeleteButtonClicked(Pane *))); - - connect(&m_audioRecordUpdateTimer, SIGNAL(timeout()), - m_paneStack, SLOT(update())); m_playSource = new AudioCallbackPlaySource(m_viewManager, QApplication::applicationName()); if (m_soundOptions & WithAudioInput) { m_recordTarget = new AudioRecordTarget(m_viewManager, QApplication::applicationName()); - connect(m_recordTarget, SIGNAL(recordDurationChanged(sv_frame_t, sv_samplerate_t)), - this, SLOT(recordDurationChanged(sv_frame_t, sv_samplerate_t))); + connect(m_recordTarget, + SIGNAL(recordDurationChanged(sv_frame_t, sv_samplerate_t)), + this, + SLOT(recordDurationChanged(sv_frame_t, sv_samplerate_t))); } connect(m_playSource, SIGNAL(sampleRateMismatch(sv_samplerate_t, sv_samplerate_t, bool)), @@ -3018,8 +3016,6 @@ currentPaneChanged(m_paneStack->getCurrentPane()); emit audioFileLoaded(); - - m_audioRecordUpdateTimer.start(1000); } void @@ -3268,8 +3264,6 @@ m_myStatusMessage = ""; getStatusLabel()->setText(""); } - - m_audioRecordUpdateTimer.stop(); } MainWindowBase::AddPaneCommand::AddPaneCommand(MainWindowBase *mw) :
--- a/framework/MainWindowBase.h Wed Jan 04 13:23:18 2017 +0000 +++ b/framework/MainWindowBase.h Wed Jan 04 14:21:24 2017 +0000 @@ -22,7 +22,6 @@ #include <QMainWindow> #include <QPointer> #include <QThread> -#include <QTimer> #include "base/Command.h" #include "view/ViewManager.h" @@ -389,7 +388,6 @@ RealTime m_defaultFfwdRwdStep; AudioRecordMode m_audioRecordMode; - QTimer m_audioRecordUpdateTimer; mutable QLabel *m_statusLabel; QLabel *getStatusLabel() const;