From 7860651ee543385bb6d1c229312b20e78150f118 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Sun, 12 Mar 2017 17:39:28 +0100 Subject: Preliminary plugin gui for disktreaming control. --- plugingui/dgwindow.h | 58 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 34 insertions(+), 24 deletions(-) (limited to 'plugingui/dgwindow.h') diff --git a/plugingui/dgwindow.h b/plugingui/dgwindow.h index 5323a12..f6fdb46 100644 --- a/plugingui/dgwindow.h +++ b/plugingui/dgwindow.h @@ -40,31 +40,21 @@ #include "texturedbox.h" #include "imagecache.h" -namespace GUI { +namespace GUI +{ class Config; class Header; class File; +class DiskStreamingControls; -class DGWindow : public Window { +class DGWindow + : public Window +{ public: - DGWindow(void* native_window, Config& config, Settings& settings); - - Header* header; - - File* drumkitFile; - LineEdit* lineedit; - ProgressBar* drumkitFileProgress; - - File* midimapFile; - LineEdit* lineedit2; - ProgressBar* midimapFileProgress; - - // Humanized velocity controls: - CheckBox* velocityCheck; - Knob* attackKnob; - Knob* falloffKnob; - FileBrowser* fileBrowser; + DGWindow(void* native_window, Config& config, Settings& settings, + SettingsNotifier& settings_notifier); + ~DGWindow(); void setDrumKitLoadStatus(LoadStatus load_status); void setMidiMapLoadStatus(LoadStatus load_status); @@ -74,6 +64,11 @@ protected: void repaintEvent(RepaintEvent* repaintEvent) override; private: + void streamerCheckClick(bool value); + void limitValueChanged(float value); + void limitSettingsValueChanged(float value); + void reloadClicked(); + void attackValueChanged(float value); void falloffValueChanged(float value); void velocityCheckClick(bool checked); @@ -82,6 +77,20 @@ private: void selectKitFile(const std::string& filename); void selectMapFile(const std::string& filename); + LineEdit* lineedit; + ProgressBar* drumkitFileProgress; + + LineEdit* lineedit2; + ProgressBar* midimapFileProgress; + + // Humanized velocity controls: + CheckBox* velocityCheck; + Knob* attackKnob; + Knob* falloffKnob; + FileBrowser* fileBrowser; + + DiskStreamingControls* disk_streaming_controls{nullptr}; + Config& config; VBoxLayout layout{this}; @@ -89,12 +98,13 @@ private: Image back{":bg.png"}; Image logo{":logo.png"}; - ImageCache image_cache; - TexturedBox sidebar{image_cache, ":sidebar.png", 0, 0, - 16, 0, 0, - 14, 1, 14}; - + ImageCache image_cache; + TexturedBox sidebar{image_cache, ":sidebar.png", 0, 0, + 16, 0, 0, + 14, 1, 14}; + Settings& settings; + SettingsNotifier& settings_notifier; }; } // GUI:: -- cgit v1.2.3