summaryrefslogtreecommitdiff
path: root/noncore/apps/keyz-cfg/zkb.cpp
Side-by-side diff
Diffstat (limited to 'noncore/apps/keyz-cfg/zkb.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/keyz-cfg/zkb.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/noncore/apps/keyz-cfg/zkb.cpp b/noncore/apps/keyz-cfg/zkb.cpp
index 58bde2a..c9e1dc5 100644
--- a/noncore/apps/keyz-cfg/zkb.cpp
+++ b/noncore/apps/keyz-cfg/zkb.cpp
@@ -1,7 +1,11 @@
#include "zkb.h"
+
+/* OPIE */
+#include <opie2/odebug.h>
+
#include <stdio.h>
// Implementation of Action class
Action::Action():state(0), keycode(0), unicode(0), flags(0) {
}
@@ -249,14 +253,14 @@ Keymap::~Keymap() {
states.clear();
}
bool Keymap::filter(int unicode, int keycode, int modifiers,
bool isPress, bool autoRepeat) {
- qDebug("filter: >>> unicode=%x, keycode=%x, modifiers=%x, "
- "ispressed=%x\n", unicode, keycode, modifiers, isPress);
+ odebug << "filter: >>> unicode=" << unicode << ", keycode=" << keycode
+ << ", modifiers=" << modifiers << ", ispressed=" << isPress << oendl;
if (!enabled) {
return false;
}
// the second check is workaround to make suspend work if
@@ -272,16 +276,14 @@ bool Keymap::filter(int unicode, int keycode, int modifiers,
Action* action = currentState->get(keycode, isPress, true);
if (action==0 || !action->isDefined()) {
return true;
}
if (action->hasEvent()) {
- qDebug("filter:<<< unicode=%x, keycode=%x, modifiers=%x, "
- "ispressed=%x\n", action->getUnicode(),
- action->getKeycode(), action->getModifiers(),
- action->isPressed());
+ odebug << "filter:<<< unicode=" << action->getUnicode() << ", keycode=" << action->getKeycode()
+ << ", modifiers=" << action->getModifiers() << ", ispressed=" << action->isPressed() << oendl;
QWSServer::sendKeyEvent(action->getUnicode(),
action->getKeycode(), action->getModifiers(),
action->isPressed(), false);
}
@@ -401,14 +403,13 @@ bool Keymap::setCurrentState(State* state) {
for(it = states.begin(); it != states.end(); ++it) {
State* s = it.data();
if (s == state) {
currentState = s;
currentStateName = it.key();
- qDebug("state changed: %s\n", (const char*)
- currentStateName.utf8());
+ odebug << "state changed: " << (const char*)currentStateName.utf8() << oendl;
if (!lsmapInSync) {
generateLabelStateMaps();
}
QMap<State*, QString>::Iterator tit;
@@ -460,17 +461,16 @@ bool Keymap::removeState(const QString& name, bool force) {
return true;
}
void Keymap::autoRepeat() {
if (autoRepeatAction != 0) {
- qDebug("filter:<<< unicode=%x, keycode=%x, modifiers=%x, "
- "ispressed=%x\n", autoRepeatAction->getUnicode(),
- autoRepeatAction->getKeycode(),
- autoRepeatAction->getModifiers(),
- autoRepeatAction->isPressed());
+ odebug << "filter:<<< unicode=" << autoRepeatAction->getUnicode()
+ << ", keycode=" << autoRepeatAction->getKeycode()
+ << ", modifiers=" << autoRepeatAction->getModifiers()
+ << "ispressed=" << autoRepeatAction->isPressed() << oendl;
QWSServer::sendKeyEvent(autoRepeatAction->getUnicode(),
autoRepeatAction->getKeycode(),
autoRepeatAction->getModifiers(),
autoRepeatAction->isPressed(), true);
}