Changeset View
Changeset View
Standalone View
Standalone View
platform.h
Show First 20 Lines • Show All 84 Lines • ▼ Show 20 Line(s) | 62 | public: | |||
---|---|---|---|---|---|
85 | /** | 85 | /** | ||
86 | * The EGLDisplay used by the compositing scene. | 86 | * The EGLDisplay used by the compositing scene. | ||
87 | **/ | 87 | **/ | ||
88 | EGLDisplay sceneEglDisplay() const; | 88 | EGLDisplay sceneEglDisplay() const; | ||
89 | void setSceneEglDisplay(EGLDisplay display); | 89 | void setSceneEglDisplay(EGLDisplay display); | ||
90 | /** | 90 | /** | ||
91 | * The EGLContext used by the compositing scene. | 91 | * The EGLContext used by the compositing scene. | ||
92 | **/ | 92 | **/ | ||
93 | virtual EGLContext sceneEglContext() const; | 93 | virtual EGLContext sceneEglContext() const { | ||
94 | return m_context; | ||||
95 | } | ||||
96 | /** | ||||
97 | * Sets the @p context used by the compositing scene. | ||||
98 | **/ | ||||
99 | void setSceneEglContext(EGLContext context) { | ||||
100 | m_context = context; | ||||
101 | } | ||||
94 | /** | 102 | /** | ||
95 | * The first (in case of multiple) EGLSurface used by the compositing scene. | 103 | * The first (in case of multiple) EGLSurface used by the compositing scene. | ||
96 | **/ | 104 | **/ | ||
97 | EGLSurface sceneEglSurface() const; | 105 | EGLSurface sceneEglSurface() const { | ||
106 | return m_surface; | ||||
107 | } | ||||
108 | /** | ||||
109 | * Sets the first @p surface used by the compositing scene. | ||||
110 | * @see sceneEglSurface | ||||
111 | **/ | ||||
112 | void setSceneEglSurface(EGLSurface surface) { | ||||
113 | m_surface = surface; | ||||
114 | } | ||||
98 | 115 | | |||
99 | /** | 116 | /** | ||
100 | * The EglConfig used by the compositing scene. | 117 | * The EglConfig used by the compositing scene. | ||
101 | **/ | 118 | **/ | ||
102 | EGLConfig sceneEglConfig() const; | 119 | EGLConfig sceneEglConfig() const { | ||
120 | return m_eglConfig; | ||||
121 | } | ||||
122 | /** | ||||
123 | * Sets the @p config used by the compositing scene. | ||||
124 | * @see sceneEglConfig | ||||
125 | **/ | ||||
126 | void setSceneEglConfig(EGLConfig config) { | ||||
127 | m_eglConfig = config; | ||||
128 | } | ||||
103 | 129 | | |||
104 | /** | 130 | /** | ||
105 | * Implementing subclasses should provide a size in case the backend represents | 131 | * Implementing subclasses should provide a size in case the backend represents | ||
106 | * a basic screen and uses the BasicScreens. | 132 | * a basic screen and uses the BasicScreens. | ||
107 | * | 133 | * | ||
108 | * Base implementation returns an invalid size. | 134 | * Base implementation returns an invalid size. | ||
109 | **/ | 135 | **/ | ||
110 | virtual QSize screenSize() const; | 136 | virtual QSize screenSize() const; | ||
▲ Show 20 Lines • Show All 320 Lines • ▼ Show 20 Line(s) | 450 | private: | |||
431 | bool m_ready = false; | 457 | bool m_ready = false; | ||
432 | QSize m_initialWindowSize; | 458 | QSize m_initialWindowSize; | ||
433 | QByteArray m_deviceIdentifier; | 459 | QByteArray m_deviceIdentifier; | ||
434 | bool m_pointerWarping = false; | 460 | bool m_pointerWarping = false; | ||
435 | bool m_outputsEnabled = true; | 461 | bool m_outputsEnabled = true; | ||
436 | int m_initialOutputCount = 1; | 462 | int m_initialOutputCount = 1; | ||
437 | qreal m_initialOutputScale = 1; | 463 | qreal m_initialOutputScale = 1; | ||
438 | EGLDisplay m_eglDisplay; | 464 | EGLDisplay m_eglDisplay; | ||
465 | EGLConfig m_eglConfig = nullptr; | ||||
466 | EGLContext m_context = EGL_NO_CONTEXT; | ||||
467 | EGLSurface m_surface = EGL_NO_SURFACE; | ||||
439 | int m_hideCursorCounter = 0; | 468 | int m_hideCursorCounter = 0; | ||
440 | }; | 469 | }; | ||
441 | 470 | | |||
442 | } | 471 | } | ||
443 | 472 | | |||
444 | Q_DECLARE_INTERFACE(KWin::Platform, "org.kde.kwin.Platform") | 473 | Q_DECLARE_INTERFACE(KWin::Platform, "org.kde.kwin.Platform") | ||
445 | 474 | | |||
446 | #endif | 475 | #endif |