diff options
Diffstat (limited to 'src/library/recording')
-rw-r--r-- | src/library/recording/dlgrecording.cpp | 56 | ||||
-rw-r--r-- | src/library/recording/recordingfeature.cpp | 30 |
2 files changed, 57 insertions, 29 deletions
diff --git a/src/library/recording/dlgrecording.cpp b/src/library/recording/dlgrecording.cpp index 684d06fe7d..b6299c31db 100644 --- a/src/library/recording/dlgrecording.cpp +++ b/src/library/recording/dlgrecording.cpp @@ -23,23 +23,39 @@ DlgRecording::DlgRecording(QWidget* parent, UserSettingsPointer pConfig, m_pTrackTableView = new WTrackTableView(this, pConfig, m_pTrackCollection, true); m_pTrackTableView->installEventFilter(pKeyboard); - connect(m_pTrackTableView, SIGNAL(loadTrack(TrackPointer)), - this, SIGNAL(loadTrack(TrackPointer))); - connect(m_pTrackTableView, SIGNAL(loadTrackToPlayer(TrackPointer, QString, bool)), - this, SIGNAL(loadTrackToPlayer(TrackPointer, QString, bool))); - connect(pLibrary, SIGNAL(setTrackTableFont(QFont)), - m_pTrackTableView, SLOT(setTrackTableFont(QFont))); - connect(pLibrary, SIGNAL(setTrackTableRowHeight(int)), - m_pTrackTableView, SLOT(setTrackTableRowHeight(int))); - connect(pLibrary, SIGNAL(setSelectedClick(bool)), - m_pTrackTableView, SLOT(setSelectedClick(bool))); - - connect(m_pRecordingManager, SIGNAL(isRecording(bool)), - this, SLOT(slotRecordingEnabled(bool))); - connect(m_pRecordingManager, SIGNAL(bytesRecorded(int)), - this, SLOT(slotBytesRecorded(int))); - connect(m_pRecordingManager, SIGNAL(durationRecorded(QString)), - this, SLOT(slotDurationRecorded(QString))); + connect(m_pTrackTableView, + &WTrackTableView::loadTrack, + this, + &DlgRecording::loadTrack); + connect(m_pTrackTableView, + &WTrackTableView::loadTrackToPlayer, + this, + &DlgRecording::loadTrackToPlayer); + connect(pLibrary, + &Library::setTrackTableFont, + m_pTrackTableView, + &WTrackTableView::setTrackTableFont); + connect(pLibrary, + &Library::setTrackTableRowHeight, + m_pTrackTableView, + &WTrackTableView::setTrackTableRowHeight); + connect(pLibrary, + &Library::setSelectedClick, + m_pTrackTableView, + &WTrackTableView::setSelectedClick); + + connect(m_pRecordingManager, + &RecordingManager::isRecording, + this, + &DlgRecording::slotRecordingEnabled); + connect(m_pRecordingManager, + &RecordingManager::bytesRecorded, + this, + &DlgRecording::slotBytesRecorded); + connect(m_pRecordingManager, + &RecordingManager::durationRecorded, + this, + &DlgRecording::slotDurationRecorded); QBoxLayout* box = dynamic_cast<QBoxLayout*>(layout()); VERIFY_OR_DEBUG_ASSERT(box) { //Assumes the form layout is a QVBox/QHBoxLayout! @@ -57,8 +73,10 @@ DlgRecording::DlgRecording(QWidget* parent, UserSettingsPointer pConfig, m_browseModel.setPath(m_recordingDir); m_pTrackTableView->loadTrackModel(&m_proxyModel); - connect(pushButtonRecording, SIGNAL(toggled(bool)), - this, SLOT(toggleRecording(bool))); + connect(pushButtonRecording, + &QPushButton::toggled, + this, + &DlgRecording::toggleRecording); label->setText(""); label->setEnabled(false); } diff --git a/src/library/recording/recordingfeature.cpp b/src/library/recording/recordingfeature.cpp index 22c436ee3a..dbec0de53f 100644 --- a/src/library/recording/recordingfeature.cpp +++ b/src/library/recording/recordingfeature.cpp @@ -51,16 +51,26 @@ void RecordingFeature::bindWidget(WLibrary* pLibraryWidget, pRecordingView->installEventFilter(keyboard); pLibraryWidget->registerView(m_sRecordingViewName, pRecordingView); - connect(pRecordingView, SIGNAL(loadTrack(TrackPointer)), - this, SIGNAL(loadTrack(TrackPointer))); - connect(pRecordingView, SIGNAL(loadTrackToPlayer(TrackPointer, QString, bool)), - this, SIGNAL(loadTrackToPlayer(TrackPointer, QString, bool))); - connect(this, SIGNAL(refreshBrowseModel()), - pRecordingView, SLOT(refreshBrowseModel())); - connect(this, SIGNAL(requestRestoreSearch()), - pRecordingView, SLOT(slotRestoreSearch())); - connect(pRecordingView, SIGNAL(restoreSearch(QString)), - this, SIGNAL(restoreSearch(QString))); + connect(pRecordingView, + &DlgRecording::loadTrack, + this, + &RecordingFeature::loadTrack); + connect(pRecordingView, + &DlgRecording::loadTrackToPlayer, + this, + &RecordingFeature::loadTrackToPlayer); + connect(this, + &RecordingFeature::refreshBrowseModel, + pRecordingView, + &DlgRecording::refreshBrowseModel); + connect(this, + &RecordingFeature::requestRestoreSearch, + pRecordingView, + &DlgRecording::slotRestoreSearch); + connect(pRecordingView, + &DlgRecording::restoreSearch, + this, + &RecordingFeature::restoreSearch); } |