Revert "Don't flush in SurfaceInterface::frameRendered()"
This reverts commit3cf004b68e
. Unfortunately,3cf004b
broke a couple of tests in kwin due to Qt not emitting QAbstractEventDispatcher::aboutToBlock() signal when macros such as QTRY_VERIFY() or QTRY_COMPARE() spin the event loop.
This commit is contained in:
parent
3cf004b68e
commit
a930e59fcf
1 changed files with 4 additions and 0 deletions
|
@ -426,6 +426,7 @@ QList<SurfaceInterface *> SurfaceInterface::surfaces()
|
|||
void SurfaceInterface::frameRendered(quint32 msec)
|
||||
{
|
||||
// notify all callbacks
|
||||
const bool needsFlush = !d->current.frameCallbacks.isEmpty();
|
||||
while (!d->current.frameCallbacks.isEmpty()) {
|
||||
KWaylandFrameCallback *frameCallback = d->current.frameCallbacks.takeFirst();
|
||||
frameCallback->send_done(msec);
|
||||
|
@ -438,6 +439,9 @@ void SurfaceInterface::frameRendered(quint32 msec)
|
|||
}
|
||||
subSurface->d_func()->surface->frameRendered(msec);
|
||||
}
|
||||
if (needsFlush) {
|
||||
client()->flush();
|
||||
}
|
||||
}
|
||||
|
||||
QMatrix4x4 SurfaceInterfacePrivate::buildSurfaceToBufferMatrix(const State *state)
|
||||
|
|
Loading…
Reference in a new issue