Blackberry: Fix hardware button detection on the BB Dev Alpha

The format of the PPS object has changed, it is now prefixed with
[n], so be more leninent in parsing to support both formats.

Change-Id: I54eb1502a6231acf2dd121531539435c59d7d668
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
This commit is contained in:
Thomas McGuire 2012-09-27 14:34:09 +02:00 committed by The Qt Project
parent ad4c76d938
commit fda3fac1d2

View File

@ -192,7 +192,7 @@ bool QQnxButtonEventNotifier::parsePPS(const QByteArray &ppsData, QHash<QByteArr
QList<QByteArray> lines = ppsData.split('\n');
// validate pps object
if (lines.size() == 0 || lines.at(0) != QByteArrayLiteral("@status")) {
if (lines.size() == 0 || !lines.at(0).contains(QByteArrayLiteral("@status"))) {
qWarning("QQNX: unrecognized pps object, data=%s", ppsData.constData());
return false;
}