Diffstat (limited to 'noncore/apps/keyz-cfg/zkbxml.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/keyz-cfg/zkbxml.cpp | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/noncore/apps/keyz-cfg/zkbxml.cpp b/noncore/apps/keyz-cfg/zkbxml.cpp index 76472cb..5b0084c 100644 --- a/noncore/apps/keyz-cfg/zkbxml.cpp +++ b/noncore/apps/keyz-cfg/zkbxml.cpp | |||
@@ -489,23 +489,17 @@ void ZkbXmlHandler::setError(const QString& e) { | |||
489 | int ZkbXmlHandler::str2key(const QString& s) { | 489 | int ZkbXmlHandler::str2key(const QString& s) { |
490 | int ret; | 490 | int ret; |
491 | 491 | ||
492 | #ifdef USE_ZKB_NAMES | ||
493 | ret = KeyNames::find(s); | 492 | ret = KeyNames::find(s); |
494 | if (ret == -1) { | 493 | if (ret == -1) { |
495 | setError("Invalid value: " + s); | 494 | setError("Invalid value: " + s); |
496 | } | 495 | } |
497 | 496 | ||
498 | #else | ||
499 | ret = str2uint(s); | ||
500 | #endif | ||
501 | |||
502 | return ret; | 497 | return ret; |
503 | } | 498 | } |
504 | 499 | ||
505 | int ZkbXmlHandler::str2modifier(const QString& val) { | 500 | int ZkbXmlHandler::str2modifier(const QString& val) { |
506 | int ret; | 501 | int ret; |
507 | 502 | ||
508 | #ifdef USE_ZKB_NAMES | ||
509 | int n, i; | 503 | int n, i; |
510 | ret = 0; | 504 | ret = 0; |
511 | n = 0; | 505 | n = 0; |
@@ -526,9 +520,6 @@ int ZkbXmlHandler::str2modifier(const QString& val) { | |||
526 | ret |= v; | 520 | ret |= v; |
527 | n = i + 1; | 521 | n = i + 1; |
528 | } while (n < val.length()); | 522 | } while (n < val.length()); |
529 | #else | ||
530 | ret = str2uint(val); | ||
531 | #endif | ||
532 | 523 | ||
533 | return ret; | 524 | return ret; |
534 | } | 525 | } |
@@ -548,16 +539,11 @@ int ZkbXmlHandler::str2unicode(const QString& s) { | |||
548 | int ZkbXmlHandler::str2keycode(const QString& s) { | 539 | int ZkbXmlHandler::str2keycode(const QString& s) { |
549 | int ret; | 540 | int ret; |
550 | 541 | ||
551 | #ifdef USE_ZKB_NAMES | ||
552 | ret = KeycodeNames::find(s); | 542 | ret = KeycodeNames::find(s); |
553 | if (ret == -1) { | 543 | if (ret == -1) { |
554 | setError("Invalid value: " + s); | 544 | setError("Invalid value: " + s); |
555 | } | 545 | } |
556 | 546 | ||
557 | #else | ||
558 | ret = str2uint(s); | ||
559 | #endif | ||
560 | |||
561 | return ret; | 547 | return ret; |
562 | } | 548 | } |
563 | 549 | ||