Search
SailfishOS Open Build Service
>
Projects
>
zephyr
:
devel:mw
>
qtwayland-nogl
> nogl-everywhere.patch
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File nogl-everywhere.patch of Package qtwayland-nogl
diff -ru qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b/examples/qwidget-compositor/main.cpp qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b-nogl2/examples/qwidget-compositor/main.cpp --- qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b/examples/qwidget-compositor/main.cpp 2012-12-13 21:46:18.000000000 +0000 +++ qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b-nogl2/examples/qwidget-compositor/main.cpp 2013-02-06 12:57:15.135894285 +0000 @@ -122,7 +122,7 @@ Q_UNUSED(rect); update(); #else - update(rect.translated(surface->geometry().topLeft())); + update(); #endif } @@ -184,10 +184,10 @@ #else //hmmm, this is actually untested :( QImage composeSurface(WaylandSurface *surface) { - Q_ASSER(surface->type() == WaylandSurface::Shm); + Q_ASSERT(surface->type() == WaylandSurface::Shm); QImage img = surface->image(); QPainter p(&img); - paintChildren(surface,p,surface); + paintChildren(surface, &p, surface); return img; } @@ -199,10 +199,9 @@ QLinkedListIterator<WaylandSurface *> i(surface->subSurfaces()); while (i.hasNext()) { WaylandSurface *subSurface = i.next(); - QPoint p = subSurface->mapTo(window,QPoint(0,0)); - QRect geo = subSurface->geometry(); - geo.moveTo(p); - if (geo.isValid()) { + QPointF p = subSurface->mapTo(window,QPoint(0,0)); + QSize size = subSurface->size(); + if (size.isValid()) { painter->drawImage(p,subSurface->image()); } paintChildren(subSurface,painter,window); @@ -235,7 +234,7 @@ m_textureBlitter->drawTexture(texture,geo,size(),0,false,m_surfaces.at(i)->isYInverted()); #else QImage img = composeSurface(m_surfaces.at(i)); - p.drawImage(m_surfaces.at(i)->geometry().topLeft(),img); + p.drawImage(m_surfaces.at(i)->pos(),img); #endif //QT_COMPOSITOR_WAYLAND_GL } diff -ru qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b/src/compositor/compositor.pro qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b-nogl2/src/compositor/compositor.pro --- qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b/src/compositor/compositor.pro 2012-12-13 21:46:18.000000000 +0000 +++ qtwayland-opensource-src-0.0-git803.g4323bf663ea131897857ff564943b17e914ccd9b-nogl2/src/compositor/compositor.pro 2013-02-06 12:02:33.512237313 +0000 @@ -1,7 +1,11 @@ TARGET = QtCompositor QT = core gui-private -contains(QT_CONFIG, opengl):MODULE_DEFINES = QT_COMPOSITOR_WAYLAND_GL +isEmpty(QT_WAYLAND_GL_CONFIG):QT_WAYLAND_GL_CONFIG = $$(QT_WAYLAND_GL_CONFIG) + +!isEqual(QT_WAYLAND_GL_CONFIG,nogl) { + contains(QT_CONFIG, opengl):MODULE_DEFINES = QT_COMPOSITOR_WAYLAND_GL +} load(qt_module)