# HG changeset patch # User Chris Cannam # Date 1483536198 0 # Node ID 5369359351cb580d218c94476892617c14cf39ca # Parent 6f54789f312790a9d17deec2988b0435a2b78065 Add record update timer (very crude this) diff -r 6f54789f3127 -r 5369359351cb framework/MainWindowBase.cpp --- a/framework/MainWindowBase.cpp Wed Jan 04 11:48:03 2017 +0000 +++ b/framework/MainWindowBase.cpp Wed Jan 04 13:23:18 2017 +0000 @@ -158,6 +158,7 @@ m_initialDarkBackground(false), m_defaultFfwdRwdStep(2, 0), m_audioRecordMode(RecordCreateAdditionalModel), + m_audioRecordUpdateTimer(this), m_statusLabel(0), m_iconsVisibleInMenus(true), m_menuShortcutMapper(0) @@ -231,6 +232,9 @@ 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) { @@ -480,7 +484,7 @@ QTimer *oscTimer = new QTimer(this); connect(oscTimer, SIGNAL(timeout()), this, SLOT(pollOSC())); oscTimer->start(1000); - cerr << "Finished setting up OSC interface" << endl; + SVCERR << "Finished setting up OSC interface" << endl; } } @@ -3014,6 +3018,8 @@ currentPaneChanged(m_paneStack->getCurrentPane()); emit audioFileLoaded(); + + m_audioRecordUpdateTimer.start(1000); } void @@ -3262,6 +3268,8 @@ m_myStatusMessage = ""; getStatusLabel()->setText(""); } + + m_audioRecordUpdateTimer.stop(); } MainWindowBase::AddPaneCommand::AddPaneCommand(MainWindowBase *mw) : diff -r 6f54789f3127 -r 5369359351cb framework/MainWindowBase.h --- a/framework/MainWindowBase.h Wed Jan 04 11:48:03 2017 +0000 +++ b/framework/MainWindowBase.h Wed Jan 04 13:23:18 2017 +0000 @@ -13,8 +13,8 @@ COPYING included with this distribution for more information. */ -#ifndef _MAIN_WINDOW_BASE_H_ -#define _MAIN_WINDOW_BASE_H_ +#ifndef SV_MAIN_WINDOW_BASE_H +#define SV_MAIN_WINDOW_BASE_H #include #include @@ -22,6 +22,7 @@ #include #include #include +#include #include "base/Command.h" #include "view/ViewManager.h" @@ -388,7 +389,8 @@ RealTime m_defaultFfwdRwdStep; AudioRecordMode m_audioRecordMode; - + QTimer m_audioRecordUpdateTimer; + mutable QLabel *m_statusLabel; QLabel *getStatusLabel() const;