aboutsummaryrefslogtreecommitdiff
path: root/qmidiplayer-desktop/qmpmainwindow.hpp
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2020-04-19 23:36:48 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2020-04-19 23:36:48 +0800
commit6d568d07b31ba2ae39703cfd272d3003ea542018 (patch)
tree58dca1ac27ffe9dd6bb045c5a71d04644b7a2e07 /qmidiplayer-desktop/qmpmainwindow.hpp
parentc7bf3e37e6eaed6895c797f72ef116b42c6f8a44 (diff)
downloadQMidiPlayer-6d568d07b31ba2ae39703cfd272d3003ea542018.tar.xz
Legacy code massacre!
Complete reconstruction of the settings infrastructure. All options are now registered using a revamped option API. Legacy configuration files are no longer compatible. Please make a backup.
Diffstat (limited to 'qmidiplayer-desktop/qmpmainwindow.hpp')
-rw-r--r--qmidiplayer-desktop/qmpmainwindow.hpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/qmidiplayer-desktop/qmpmainwindow.hpp b/qmidiplayer-desktop/qmpmainwindow.hpp
index c8f3827..700b501 100644
--- a/qmidiplayer-desktop/qmpmainwindow.hpp
+++ b/qmidiplayer-desktop/qmpmainwindow.hpp
@@ -141,7 +141,7 @@ class qmpMainWindow:public QMainWindow
void dragEnterEvent(QDragEnterEvent *event);
~qmpMainWindow();
CMidiPlayer* getPlayer(){return player;}
- qmpSettingsWindow* getSettingsWindow(){return settingsw;}
+ qmpSettings* getSettings(){return settings.get();}
QTimer* getTimer(){return timer;}
bool isFinalizing(){return fin;}
QString getFileName();
@@ -163,7 +163,6 @@ class qmpMainWindow:public QMainWindow
void reloadSynth();
void setupWidget();
void invokeCallback(std::string cat,void *callerdat);
- std::vector<std::string>& getWidgets(int w);
std::map<std::string,qmpFuncPrivate>& getFunc();
private slots:
@@ -200,8 +199,9 @@ class qmpMainWindow:public QMainWindow
QPointer<qmpChannelsWindow> chnlw;
QPointer<qmpEfxWindow> efxw;
QPointer<qmpInfoWindow> infow;
- QPointer<qmpSettingsWindow> settingsw;
QPointer<qmpHelpWindow> helpw;
+ std::unique_ptr<qmpSettings> settings;
+ QPointer<qmpSettingsWindow> settingsw;
std::map<std::string,qmpFuncPrivate> mfunc;
std::unordered_map<std::string,std::map<int,std::pair<qmpCallBack,void*>>> muicb;
qmpRenderFunc* renderf;
@@ -215,6 +215,8 @@ class qmpMainWindow:public QMainWindow
void playerSetup(IFluidSettings *fs);
void loadSoundFont(IFluidSettings *fs);
int loadFile(QString fns);
+ void registerMidiOptions();
+ void registerBehaviorOptions();
private:
static qmpMainWindow* ref;