summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorWolfgang Bremer <wbremer@blackberry.com>2014-01-16 11:18:25 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-17 12:25:48 +0100
commit93154216ca7c7a46836716150fe70987d28d6f3c (patch)
tree836e4075532fc92aab560b3afd871e6538af8b79 /src
parent11442778ed52ee6c6341ed04df0eaabc8af95bc6 (diff)
Fix BlackBerry10 build on NDKs prior to 10.2.1
This commit adds a dependency checking for a recently introduced define. On NDKs 10.2.1 and later it compiles with support for VIRTUALKEYBOARD_LAYOUT_ALPHANUMERIC. NDKs 10.2.0 and earlier do not know this define and therefore it will be ignored. This is necessary because there is no newer NDK publicly available than 10.2.0. Assuming pure QNX SDKs are missing the define completely, we are only including it on recent BB NDKs. Change-Id: I6f814e5c2d77c50edf8534f3567b157f71147555 Reviewed-by: Peter Hartmann <phartmann@blackberry.com> Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
Diffstat (limited to 'src')
-rw-r--r--src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp b/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
index b154638865..08de94a082 100644
--- a/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
+++ b/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
@@ -46,6 +46,9 @@
#include <bps/event.h>
#include <bps/locale.h>
#include <bps/virtualkeyboard.h>
+#if defined(Q_OS_BLACKBERRY)
+#include <bbndk.h>
+#endif
#if defined(QQNXVIRTUALKEYBOARD_DEBUG)
#define qVirtualKeyboardDebug qDebug
@@ -133,8 +136,12 @@ virtualkeyboard_layout_t QQnxVirtualKeyboardBps::keyboardLayout() const
return VIRTUALKEYBOARD_LAYOUT_PIN;
case Password:
return VIRTUALKEYBOARD_LAYOUT_PASSWORD;
+#if defined(Q_OS_BLACKBERRY)
+#if BBNDK_VERSION_AT_LEAST(10, 2, 1)
case Alphanumeric:
return VIRTUALKEYBOARD_LAYOUT_ALPHANUMERIC;
+#endif
+#endif
case Default: // fall through
default:
return VIRTUALKEYBOARD_LAYOUT_DEFAULT;