diff options
author | Jonathan Maw <jonathan.maw@codethink.co.uk> | 2015-04-21 14:20:43 +0000 |
---|---|---|
committer | Pedro Alvarez <pedro.alvarez@codethink.co.uk> | 2016-01-11 17:53:58 +0000 |
commit | eec1488b0b9718f44927cec3d6a7d6d205dc7661 (patch) | |
tree | 708a9b7b08ff1bca6d55fa6e61302137f6fd5112 | |
parent | d1fa7975a67836b305539079685168d185866184 (diff) | |
download | qtwayland-baserock/pedroalvarez/genivi-5.4.2-wip.tar.gz |
Use IVI-Surface-IDbaserock/pedroalvarez/genivi-5.4.2-wip
This is adapted off a patch by Holger Behrens <holger.behrens@windriver.com>
-rw-r--r-- | src/client/qwaylandwindow.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp index d7ff50b9..7c3091ba 100644 --- a/src/client/qwaylandwindow.cpp +++ b/src/client/qwaylandwindow.cpp @@ -101,7 +101,14 @@ QWaylandWindow::QWaylandWindow(QWindow *window) if (mDisplay->subSurfaceExtension()) mSubSurfaceWindow = new QWaylandSubSurface(this, mDisplay->subSurfaceExtension()->get_sub_surface_aware_surface(object())); if (mDisplay->iviApplication() && (window->type() & Qt::Window)) { - mIviSurface = new QWaylandIviSurface(mDisplay->iviApplication()->surface_create((uint32_t)QCoreApplication::applicationPid(), object()), this); + unsigned int id = 0; + QVariant value = window->property("IVI-Surface-ID"); + if (value.isValid()) + id = value.toUInt(); + else + id = (uint32_t)QCoreApplication::applicationPid(); + + mIviSurface = new QWaylandIviSurface(mDisplay->iviApplication()->surface_create(id, object()), this); } if (!(window->flags() & Qt::BypassWindowManagerHint)) { mShellSurface = mDisplay->createShellSurface(this); |