summaryrefslogtreecommitdiff
path: root/rbutil/rbutilqt/rbutilqt.h
diff options
context:
space:
mode:
authorDominik Riebeling <Dominik.Riebeling@gmail.com>2011-10-02 14:30:05 +0000
committerDominik Riebeling <Dominik.Riebeling@gmail.com>2011-10-02 14:30:05 +0000
commit2e3de70401379c044fdd3696e7cc6dc78aace808 (patch)
tree1e208b0dc8be1d0377f0c47533d3e839448473f6 /rbutil/rbutilqt/rbutilqt.h
parentd25341a032a19985af85c72b95964bef812971c3 (diff)
downloadrockbox-2e3de70401379c044fdd3696e7cc6dc78aace808.tar.gz
rockbox-2e3de70401379c044fdd3696e7cc6dc78aace808.zip
Rockbox Utility: listen to translation change events.
When changing the language don't require a restart anymore. Instead listen to the appropriate changeEvent and retranslate the UI. Designer generated UI files already provide such a function. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30633 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/rbutilqt/rbutilqt.h')
-rw-r--r--rbutil/rbutilqt/rbutilqt.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/rbutil/rbutilqt/rbutilqt.h b/rbutil/rbutilqt/rbutilqt.h
index 42656540e6..869eb98f44 100644
--- a/rbutil/rbutilqt/rbutilqt.h
+++ b/rbutil/rbutilqt/rbutilqt.h
@@ -25,6 +25,8 @@
25 25
26#include <QSettings> 26#include <QSettings>
27#include <QTemporaryFile> 27#include <QTemporaryFile>
28#include <QList>
29#include <QTranslator>
28 30
29#include "ui_rbutilqtfrm.h" 31#include "ui_rbutilqtfrm.h"
30#include "httpget.h" 32#include "httpget.h"
@@ -38,10 +40,12 @@ class RbUtilQt : public QMainWindow
38 40
39 public: 41 public:
40 RbUtilQt(QWidget *parent = 0); 42 RbUtilQt(QWidget *parent = 0);
43 static QList<QTranslator*> translators;
41 44
42 private: 45 private:
43 Ui::RbUtilQtFrm ui; 46 Ui::RbUtilQtFrm ui;
44 47
48 void changeEvent(QEvent *e);
45 void initDeviceNames(void); 49 void initDeviceNames(void);
46 QString deviceName(QString); 50 QString deviceName(QString);
47 QString platform; 51 QString platform;
@@ -110,7 +114,7 @@ class RbUtilQt : public QMainWindow
110 void installPortable(void); 114 void installPortable(void);
111 void updateInfo(void); 115 void updateInfo(void);
112 void updateTabs(int); 116 void updateTabs(int);
113 117
114 void checkUpdate(void); 118 void checkUpdate(void);
115 void downloadUpdateDone(bool errror); 119 void downloadUpdateDone(bool errror);
116}; 120};