Diffstat (limited to 'libopie2/opiecore/okeyconfigmanager.h') (more/less context) (show whitespace changes)
-rw-r--r-- | libopie2/opiecore/okeyconfigmanager.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libopie2/opiecore/okeyconfigmanager.h b/libopie2/opiecore/okeyconfigmanager.h index d0a6247..12804ee 100644 --- a/libopie2/opiecore/okeyconfigmanager.h +++ b/libopie2/opiecore/okeyconfigmanager.h | |||
@@ -57,25 +57,25 @@ private: | |||
57 | int m_key; | 57 | int m_key; |
58 | int m_mod; | 58 | int m_mod; |
59 | class Private; | 59 | class Private; |
60 | Private* d; | 60 | Private* d; |
61 | }; | 61 | }; |
62 | 62 | ||
63 | /** | 63 | /** |
64 | * A class to represent an OKeyPair. | 64 | * A class to represent an OKeyPair. |
65 | * It consists out of a Text exposed to the user, Config Key Item, | 65 | * It consists out of a Text exposed to the user, Config Key Item, |
66 | * Pixmap, A default OKeyPair and the set OKeyPair. | 66 | * Pixmap, A default OKeyPair and the set OKeyPair. |
67 | * You can also pass an id to it | 67 | * You can also pass an id to it |
68 | * | 68 | * |
69 | * @since 1.1.2 | 69 | * @since 1.2 |
70 | */ | 70 | */ |
71 | class OKeyConfigItem { | 71 | class OKeyConfigItem { |
72 | friend class OKeyConfigManager; | 72 | friend class OKeyConfigManager; |
73 | public: | 73 | public: |
74 | typedef QValueList<OKeyConfigItem> List; | 74 | typedef QValueList<OKeyConfigItem> List; |
75 | OKeyConfigItem( const QString& text = QString::null , const QCString& config_key = QCString(), | 75 | OKeyConfigItem( const QString& text = QString::null , const QCString& config_key = QCString(), |
76 | const QPixmap& symbol = QPixmap(), | 76 | const QPixmap& symbol = QPixmap(), |
77 | int id = -1, | 77 | int id = -1, |
78 | const OKeyPair& def = OKeyPair::emptyKey(), | 78 | const OKeyPair& def = OKeyPair::emptyKey(), |
79 | QObject *caller = 0, const char* slot = 0); | 79 | QObject *caller = 0, const char* slot = 0); |
80 | OKeyConfigItem( const Opie::Core::ODeviceButton& ); | 80 | OKeyConfigItem( const Opie::Core::ODeviceButton& ); |
81 | ~OKeyConfigItem(); | 81 | ~OKeyConfigItem(); |
@@ -147,41 +147,42 @@ public: | |||
147 | enum EventMask { | 147 | enum EventMask { |
148 | MaskPressed = 0x1, | 148 | MaskPressed = 0x1, |
149 | MaskReleased = 0x2, | 149 | MaskReleased = 0x2, |
150 | }; | 150 | }; |
151 | 151 | ||
152 | OKeyConfigManager(Opie::Core::OConfig *conf = 0, | 152 | OKeyConfigManager(Opie::Core::OConfig *conf = 0, |
153 | const QString& group = QString::null, | 153 | const QString& group = QString::null, |
154 | const OKeyPair::List &block = OKeyPair::List(), | 154 | const OKeyPair::List &block = OKeyPair::List(), |
155 | bool grabkeyboard = false, QObject * par = 0, | 155 | bool grabkeyboard = false, QObject * par = 0, |
156 | const char* name = 0 ); | 156 | const char* name = 0 ); |
157 | virtual ~OKeyConfigManager(); | 157 | virtual ~OKeyConfigManager(); |
158 | 158 | ||
159 | public slots: | ||
159 | virtual void load(); | 160 | virtual void load(); |
160 | virtual void save(); | 161 | virtual void save(); |
162 | void handleWidget( QWidget* ); | ||
161 | 163 | ||
164 | public: | ||
162 | virtual OKeyConfigItem handleKeyEvent( QKeyEvent* ); | 165 | virtual OKeyConfigItem handleKeyEvent( QKeyEvent* ); |
163 | int handleKeyEventId( QKeyEvent* ); | 166 | int handleKeyEventId( QKeyEvent* ); |
164 | 167 | ||
165 | void addKeyConfig( const OKeyConfigItem& ); | 168 | void addKeyConfig( const OKeyConfigItem& ); |
166 | void removeKeyConfig( const OKeyConfigItem& ); | 169 | void removeKeyConfig( const OKeyConfigItem& ); |
167 | void clearKeyConfig(); | 170 | void clearKeyConfig(); |
168 | 171 | ||
169 | void addToBlackList( const OKeyPair& ); | 172 | void addToBlackList( const OKeyPair& ); |
170 | void removeFromBlackList( const OKeyPair& ); | 173 | void removeFromBlackList( const OKeyPair& ); |
171 | void clearBlackList(); | 174 | void clearBlackList(); |
172 | OKeyPair::List blackList()const; | 175 | OKeyPair::List blackList()const; |
173 | 176 | ||
174 | void handleWidget( QWidget* ); | ||
175 | |||
176 | bool eventFilter( QObject*, QEvent* ); | 177 | bool eventFilter( QObject*, QEvent* ); |
177 | 178 | ||
178 | /** | 179 | /** |
179 | * Sets the event mask flags aMask. | 180 | * Sets the event mask flags aMask. |
180 | * | 181 | * |
181 | * aMask is a combination of OKeyConfigManager::EventMask | 182 | * aMask is a combination of OKeyConfigManager::EventMask |
182 | * | 183 | * |
183 | * @see eventMask(), testEventMask(), addEventMask(), clearEventMask() | 184 | * @see eventMask(), testEventMask(), addEventMask(), clearEventMask() |
184 | */ | 185 | */ |
185 | void setEventMask(uint aMask); | 186 | void setEventMask(uint aMask); |
186 | /** | 187 | /** |
187 | * Returns the event mask flags set. | 188 | * Returns the event mask flags set. |