summaryrefslogtreecommitdiffstats
path: root/src/platformsupport/eglconvenience/qeglplatformscreen.cpp
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@digia.com>2014-11-19 14:58:43 +0100
committerLaszlo Agocs <laszlo.agocs@theqtcompany.com>2014-11-26 09:31:16 +0100
commit37cce4cadace48a22cbc5252810237341a371b10 (patch)
tree8cbe588c8ee3ad7e06428736bedeac94e7f49d3e /src/platformsupport/eglconvenience/qeglplatformscreen.cpp
parente41713b21dad247aca1af493aa7e06f0822dc4ea (diff)
Add generic OpenGL compositor and backingstore bits
By removing the EGL(FS) dependencies we get classes that can be used by any platform plugin that runs without a windowing system. Change-Id: If99b42de5a4da02bbef80863609b6d92c6734613 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
Diffstat (limited to 'src/platformsupport/eglconvenience/qeglplatformscreen.cpp')
-rw-r--r--src/platformsupport/eglconvenience/qeglplatformscreen.cpp49
1 files changed, 2 insertions, 47 deletions
diff --git a/src/platformsupport/eglconvenience/qeglplatformscreen.cpp b/src/platformsupport/eglconvenience/qeglplatformscreen.cpp
index fd577a48d7..fd9befb575 100644
--- a/src/platformsupport/eglconvenience/qeglplatformscreen.cpp
+++ b/src/platformsupport/eglconvenience/qeglplatformscreen.cpp
@@ -31,8 +31,8 @@
**
****************************************************************************/
-#include "qeglcompositor_p.h"
#include "qeglplatformscreen_p.h"
+#include <QtPlatformSupport/private/qopenglcompositor_p.h>
QT_BEGIN_NAMESPACE
@@ -42,19 +42,6 @@ QT_BEGIN_NAMESPACE
\since 5.2
\internal
\ingroup qpa
-
- This class provides a lightweight base for QPlatformScreen
- implementations. It covers basic window stack management which is
- necessary when compositing multiple raster (widget-based) windows
- together into one single native surface.
-
- Reimplementing the virtuals are essential when using
- QEGLPlatformBackingStore. The context and the window returned from
- these are the ones that are used when compositing the textures
- generated from the raster (widget) based windows.
-
- \note It is up to the QEGLPlatformWindow subclasses to use the
- functions, like addWindow(), removeWindow(), etc., provided here.
*/
QEGLPlatformScreen::QEGLPlatformScreen(EGLDisplay dpy)
@@ -64,39 +51,7 @@ QEGLPlatformScreen::QEGLPlatformScreen(EGLDisplay dpy)
QEGLPlatformScreen::~QEGLPlatformScreen()
{
- QEGLCompositor::destroy();
-}
-
-void QEGLPlatformScreen::addWindow(QEGLPlatformWindow *window)
-{
- if (!m_windows.contains(window)) {
- m_windows.append(window);
- topWindowChanged(window);
- }
-}
-
-void QEGLPlatformScreen::removeWindow(QEGLPlatformWindow *window)
-{
- m_windows.removeOne(window);
- if (!m_windows.isEmpty())
- topWindowChanged(m_windows.last());
-}
-
-void QEGLPlatformScreen::moveToTop(QEGLPlatformWindow *window)
-{
- m_windows.removeOne(window);
- m_windows.append(window);
- topWindowChanged(window);
-}
-
-void QEGLPlatformScreen::changeWindowIndex(QEGLPlatformWindow *window, int newIdx)
-{
- int idx = m_windows.indexOf(window);
- if (idx != -1 && idx != newIdx) {
- m_windows.move(idx, newIdx);
- if (newIdx == m_windows.size() - 1)
- topWindowChanged(m_windows.last());
- }
+ QOpenGLCompositor::destroy();
}
QT_END_NAMESPACE