aboutsummaryrefslogtreecommitdiff
path: root/qmidiplayer-desktop/qmpsettingswindow.hpp
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2017-02-13 17:31:42 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2017-02-13 17:31:42 +0800
commita0da9bca472043e7f13d4d6ea1809f6b63a598b0 (patch)
treef318a37656b5b25c4028739b8e59ebb4d132d34d /qmidiplayer-desktop/qmpsettingswindow.hpp
parent3312e495cf54a8bd6451552216f5aeea1a06d486 (diff)
downloadQMidiPlayer-a0da9bca472043e7f13d4d6ea1809f6b63a598b0.tar.xz
Fix pitch bend range handling.
Allow registering a string option as file path. Provide an easier way to set path values in options. Revert to old geometry storage mechanism and improved it. Hope this one will work on Windows. Make the time slider less ugly.
Diffstat (limited to 'qmidiplayer-desktop/qmpsettingswindow.hpp')
-rw-r--r--qmidiplayer-desktop/qmpsettingswindow.hpp20
1 files changed, 19 insertions, 1 deletions
diff --git a/qmidiplayer-desktop/qmpsettingswindow.hpp b/qmidiplayer-desktop/qmpsettingswindow.hpp
index 16faa0f..a7d5cbb 100644
--- a/qmidiplayer-desktop/qmpsettingswindow.hpp
+++ b/qmidiplayer-desktop/qmpsettingswindow.hpp
@@ -25,8 +25,25 @@ struct qmpCustomOption
QVariant defaultval,minv,maxv;
};
+class QLineEdit;
+class QToolButton;
+class QFileEdit:public QWidget
+{
+ Q_OBJECT
+ private:
+ QLineEdit *le;
+ QToolButton *tb;
+ private slots:
+ void chooseFile();
+ public:
+ QFileEdit(QWidget* par=NULL);
+ QString text();
+ void setText(const QString& s);
+};
+
class QHexSpinBox:public QSpinBox
{
+ Q_OBJECT
public:
QHexSpinBox(QWidget *parent=0):QSpinBox(parent)
{
@@ -83,12 +100,13 @@ class qmpSettingsWindow:public QDialog
void registerOptionDouble(std::string tab,std::string desc,std::string key,double min,double max,double defaultval);
double getOptionDouble(std::string key);
void setOptionDouble(std::string key,double val);
- void registerOptionString(std::string tab,std::string desc,std::string key,std::string defaultval);
+ void registerOptionString(std::string tab,std::string desc,std::string key,std::string defaultval,bool ispath);
std::string getOptionString(std::string key);
void setOptionString(std::string key,std::string val);
void registerOptionEnumInt(std::string tab,std::string desc,std::string key,std::vector<std::string> options,int defaultval);
int getOptionEnumInt(std::string key);
void setOptionEnumInt(std::string key,int val);
+ void verifySF();
signals:
void dialogClosing();