From 627f2cb593daf219aad04cfa45668cbfa7a17a59 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Sat, 12 May 2018 16:23:54 +0200 Subject: Move instrument editor components into their own (sub)window. --- src/mainwindow.h | 66 +++----------------------------------------------------- 1 file changed, 3 insertions(+), 63 deletions(-) (limited to 'src/mainwindow.h') diff --git a/src/mainwindow.h b/src/mainwindow.h index d1df144..a7c9ba2 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -27,38 +27,14 @@ #pragma once #include -#include -#include -#include -#include #include #include -#include "canvas.h" -#include "audioextractor.h" -#include "samplesorter.h" -#include "filelist.h" -#include "canvastoolselections.h" -#include "canvastoolthreshold.h" -#include "canvastoollisten.h" -#include "selection.h" -#include "player.h" -#include "zoomslider.h" -#include "canvaswidget.h" #include "project.h" +#include "instrumentwindow.h" class Settings; -class Preset -{ -public: - QString prefix; - int attacklength; - int falloff; - int fadelength; -}; -Q_DECLARE_METATYPE(Preset) - class MainWindow : public QMainWindow { @@ -72,11 +48,6 @@ public slots: void loadProject(); void saveProject(); void projectChanged(); - void doExport(); - void loadFile(QString filename); - void playSamples(); - void browse(); - void tabChanged(int tabid); protected: void closeEvent(QCloseEvent*); @@ -85,39 +56,8 @@ private: void loadSettings(); void saveSettings(); - QWidget* createFilesTab(); - QWidget* createEditTab(); - QWidget* createGenerateTab(); - QWidget* createExportTab(); - - int generateTabId; - - SampleSorter* sorter; - CanvasToolSelections* tool_selections; - CanvasToolThreshold* threshold; - CanvasToolListen* listen; - AudioExtractor* extractor; - FileList* filelist; - - CanvasWidget* canvaswidget; - - QScrollBar* sb_playsamples; - QComboBox* presets; - QSlider* slider_attacklength; - QSlider* slider_spread; - QSlider* slider_hold; - QSlider* slider_falloff; - QSlider* slider_fadelength; - QLineEdit* prefix; - QLineEdit* lineed_exportp; - - QTabWidget* tabs; - - // Session state information: - Selections selections; - Selections selections_preview; - Player player; - Settings& settings; Project project; + + InstrumentWindow instrument_window; }; -- cgit v1.2.3