Commit 79f83259 authored by Pasi Petäjäjärvi's avatar Pasi Petäjäjärvi
Browse files

eglfs: obey QT_NO_REGULAREXPRESSION define


Not all platforms do have QRegularExpression as it is based on
pcre.

Change-Id: I6b8e701ff7cf30e776ee34e5dc836cd24c9543b5
Reviewed-by: default avatarLaszlo Agocs <laszlo.agocs@digia.com>
parent 30d94983
No related merge requests found
Showing with 2 additions and 0 deletions
......@@ -63,11 +63,13 @@ QByteArray QEglFSHooks::fbDeviceName() const
int QEglFSHooks::framebufferIndex() const
{
int fbIndex = 0;
#ifndef QT_NO_REGULAREXPRESSION
QRegularExpression fbIndexRx(QLatin1String("fb(\\d+)"));
QRegularExpressionMatch match = fbIndexRx.match(fbDeviceName());
if (match.hasMatch())
fbIndex = match.captured(1).toInt();
#endif
return fbIndex;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment