diff --git a/eglonxbackend.cpp b/eglonxbackend.cpp index dc5060b223..01d97c0b85 100644 --- a/eglonxbackend.cpp +++ b/eglonxbackend.cpp @@ -187,7 +187,7 @@ bool EglOnXBackend::initBufferConfigs() return true; } -void EglOnXBackend::flushBuffer() +void EglOnXBackend::present() { if (lastMask() & Scene::PAINT_SCREEN_REGION && surfaceHasSubPost && eglPostSubBufferNV) { const QRect damageRect = lastDamage().boundingRect(); @@ -216,7 +216,7 @@ SceneOpenGL::TexturePrivate *EglOnXBackend::createBackendTexture(SceneOpenGL::Te void EglOnXBackend::prepareRenderingFrame() { if (!lastDamage().isEmpty()) - flushBuffer(); + present(); startRenderTimer(); } diff --git a/eglonxbackend.h b/eglonxbackend.h index 4b7eb25f50..45df2af028 100644 --- a/eglonxbackend.h +++ b/eglonxbackend.h @@ -38,7 +38,7 @@ public: virtual void endRenderingFrame(int mask, const QRegion &damage); protected: - virtual void flushBuffer(); + virtual void present(); private: void init(); diff --git a/glxbackend.cpp b/glxbackend.cpp index 24fcbebf74..86eb130161 100644 --- a/glxbackend.cpp +++ b/glxbackend.cpp @@ -429,7 +429,7 @@ void GlxBackend::waitSync() #undef VSYNC_DEBUG -void GlxBackend::flushBuffer() +void GlxBackend::present() { if (isDoubleBuffer()) { if (lastMask() & Scene::PAINT_SCREEN_REGION) { @@ -535,7 +535,7 @@ SceneOpenGL::TexturePrivate *GlxBackend::createBackendTexture(SceneOpenGL::Textu void GlxBackend::prepareRenderingFrame() { if (!lastDamage().isEmpty()) - flushBuffer(); + present(); glXWaitX(); } diff --git a/glxbackend.h b/glxbackend.h index 6fd8c3032e..ee08e8dcc6 100644 --- a/glxbackend.h +++ b/glxbackend.h @@ -48,7 +48,7 @@ public: virtual void endRenderingFrame(int mask, const QRegion &damage); protected: - virtual void flushBuffer(); + virtual void present(); private: void init(); diff --git a/scene_opengl.cpp b/scene_opengl.cpp index 3f130b9bbc..9c72fc148b 100644 --- a/scene_opengl.cpp +++ b/scene_opengl.cpp @@ -133,7 +133,7 @@ void OpenGLBackend::setFailed(const QString &reason) void OpenGLBackend::idle() { - flushBuffer(); + present(); } /************************************************ diff --git a/scene_opengl.h b/scene_opengl.h index dce2b7c092..b2e851ba73 100644 --- a/scene_opengl.h +++ b/scene_opengl.h @@ -453,7 +453,7 @@ protected: /** * @brief Backend specific flushing of frame to screen. **/ - virtual void flushBuffer() = 0; + virtual void present() = 0; /** * @brief Sets the backend initialization to failed. * diff --git a/scene_xrender.cpp b/scene_xrender.cpp index 93d3502f49..f3979fed20 100644 --- a/scene_xrender.cpp +++ b/scene_xrender.cpp @@ -189,14 +189,14 @@ int SceneXrender::paint(QRegion damage, ToplevelList toplevels) if (m_overlayWindow->window()) // show the window only after the first pass, since m_overlayWindow->show(); // that pass may take long - flushBuffer(mask, damage); + present(mask, damage); // do cleanup stacking_order.clear(); return renderTimer.elapsed(); } -void SceneXrender::flushBuffer(int mask, QRegion damage) +void SceneXrender::present(int mask, QRegion damage) { if (mask & PAINT_SCREEN_REGION) { // Use the damage region as the clip region for the root window diff --git a/scene_xrender.h b/scene_xrender.h index f17259464c..645700f58a 100644 --- a/scene_xrender.h +++ b/scene_xrender.h @@ -61,7 +61,7 @@ public Q_SLOTS: virtual void windowClosed(KWin::Toplevel* c, KWin::Deleted* deleted); private: void createBuffer(); - void flushBuffer(int mask, QRegion damage); + void present(int mask, QRegion damage); void initXRender(bool createOverlay); XRenderPictFormat* format; Picture front;