Mercurial > hg > sonic-visualiser
comparison main/MainWindow.cpp @ 1063:1f92fc7a6b05 3.0-integration
Merge from branch "recording"
author | Chris Cannam |
---|---|
date | Thu, 17 Sep 2015 13:46:20 +0100 |
parents | 40ff7c801fc2 25e1cc4f34eb |
children | 6fcb632384ba |
comparison
equal
deleted
inserted
replaced
1062:9918aaf0b790 | 1063:1f92fc7a6b05 |
---|---|
301 m_activityLog, SLOT(activityHappened(QString))); | 301 m_activityLog, SLOT(activityHappened(QString))); |
302 connect(this, SIGNAL(replacedDocument()), this, SLOT(documentReplaced())); | 302 connect(this, SIGNAL(replacedDocument()), this, SLOT(documentReplaced())); |
303 m_activityLog->hide(); | 303 m_activityLog->hide(); |
304 | 304 |
305 m_unitConverter->hide(); | 305 m_unitConverter->hide(); |
306 | |
307 setAudioRecordMode(RecordCreateAdditionalModel); | |
306 | 308 |
307 newSession(); | 309 newSession(); |
308 | 310 |
309 connect(m_midiInput, SIGNAL(eventsAvailable()), | 311 connect(m_midiInput, SIGNAL(eventsAvailable()), |
310 this, SLOT(midiEventsAvailable())); | 312 this, SLOT(midiEventsAvailable())); |
579 | 581 |
580 action = new QAction(tr("Export Image File..."), this); | 582 action = new QAction(tr("Export Image File..."), this); |
581 action->setStatusTip(tr("Export a single pane to an image file")); | 583 action->setStatusTip(tr("Export a single pane to an image file")); |
582 connect(action, SIGNAL(triggered()), this, SLOT(exportImage())); | 584 connect(action, SIGNAL(triggered()), this, SLOT(exportImage())); |
583 connect(this, SIGNAL(canExportImage(bool)), action, SLOT(setEnabled(bool))); | 585 connect(this, SIGNAL(canExportImage(bool)), action, SLOT(setEnabled(bool))); |
586 menu->addAction(action); | |
587 | |
588 menu->addSeparator(); | |
589 | |
590 action = new QAction(tr("Browse Recorded Audio Folder"), this); | |
591 action->setStatusTip(tr("Open the Recorded Audio folder in the system file browser")); | |
592 connect(action, SIGNAL(triggered()), this, SLOT(browseRecordedAudio())); | |
584 menu->addAction(action); | 593 menu->addAction(action); |
585 | 594 |
586 menu->addSeparator(); | 595 menu->addSeparator(); |
587 | 596 |
588 QString templatesMenuLabel = tr("Apply Session Template"); | 597 QString templatesMenuLabel = tr("Apply Session Template"); |
2055 m_keyReference->registerShortcut(m_ffwdSimilarAction); | 2064 m_keyReference->registerShortcut(m_ffwdSimilarAction); |
2056 m_keyReference->registerShortcut(m_rwdStartAction); | 2065 m_keyReference->registerShortcut(m_rwdStartAction); |
2057 m_keyReference->registerShortcut(m_ffwdEndAction); | 2066 m_keyReference->registerShortcut(m_ffwdEndAction); |
2058 | 2067 |
2059 menu->addAction(m_playAction); | 2068 menu->addAction(m_playAction); |
2069 menu->addAction(m_recordAction); | |
2060 menu->addAction(m_playSelectionAction); | 2070 menu->addAction(m_playSelectionAction); |
2061 menu->addAction(m_playLoopAction); | 2071 menu->addAction(m_playLoopAction); |
2062 menu->addAction(m_soloAction); | 2072 menu->addAction(m_soloAction); |
2063 if (alAction) menu->addAction(alAction); | 2073 if (alAction) menu->addAction(alAction); |
2064 menu->addSeparator(); | 2074 menu->addSeparator(); |
2073 menu->addSeparator(); | 2083 menu->addSeparator(); |
2074 menu->addAction(m_recordAction); | 2084 menu->addAction(m_recordAction); |
2075 menu->addSeparator(); | 2085 menu->addSeparator(); |
2076 | 2086 |
2077 m_rightButtonPlaybackMenu->addAction(m_playAction); | 2087 m_rightButtonPlaybackMenu->addAction(m_playAction); |
2088 m_rightButtonPlaybackMenu->addAction(m_recordAction); | |
2078 m_rightButtonPlaybackMenu->addAction(m_playSelectionAction); | 2089 m_rightButtonPlaybackMenu->addAction(m_playSelectionAction); |
2079 m_rightButtonPlaybackMenu->addAction(m_playLoopAction); | 2090 m_rightButtonPlaybackMenu->addAction(m_playLoopAction); |
2080 m_rightButtonPlaybackMenu->addAction(m_soloAction); | 2091 m_rightButtonPlaybackMenu->addAction(m_soloAction); |
2081 if (alAction) m_rightButtonPlaybackMenu->addAction(alAction); | 2092 if (alAction) m_rightButtonPlaybackMenu->addAction(alAction); |
2082 m_rightButtonPlaybackMenu->addSeparator(); | 2093 m_rightButtonPlaybackMenu->addSeparator(); |
2891 QMessageBox::critical(this, tr("Failed to save image file"), | 2902 QMessageBox::critical(this, tr("Failed to save image file"), |
2892 tr("Failed to save image file %1").arg(path)); | 2903 tr("Failed to save image file %1").arg(path)); |
2893 } | 2904 } |
2894 | 2905 |
2895 delete image; | 2906 delete image; |
2907 } | |
2908 | |
2909 void | |
2910 MainWindow::browseRecordedAudio() | |
2911 { | |
2912 if (!m_recordTarget) return; | |
2913 | |
2914 QString path = m_recordTarget->getRecordFolder(); | |
2915 if (path == "") return; | |
2916 | |
2917 openLocalFolder(path); | |
2896 } | 2918 } |
2897 | 2919 |
2898 void | 2920 void |
2899 MainWindow::newSession() | 2921 MainWindow::newSession() |
2900 { | 2922 { |