1 | // Copyright (C) 2017 ITAGE Corporation, author: <yusuke.binsaki@itage.co.jp> |
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | |
4 | #ifndef QWAYLANDIVISURFACE_H |
5 | #define QWAYLANDIVISURFACE_H |
6 | |
7 | #include <QtWaylandClient/private/qwaylandshellsurface_p.h> |
8 | #include "qwayland-ivi-application.h" |
9 | #include "qwayland-ivi-controller.h" |
10 | |
11 | QT_BEGIN_NAMESPACE |
12 | |
13 | namespace QtWaylandClient { |
14 | |
15 | class QWaylandWindow; |
16 | class QWaylandInputDevice; |
17 | class QWaylandExtendedSurface; |
18 | |
19 | class Q_WAYLANDCLIENT_EXPORT QWaylandIviSurface : public QtWayland::ivi_surface |
20 | , public QWaylandShellSurface, public QtWayland::ivi_controller_surface |
21 | { |
22 | public: |
23 | QWaylandIviSurface(struct ::ivi_surface *shell_surface, QWaylandWindow *window); |
24 | QWaylandIviSurface(struct ::ivi_surface *shell_surface, QWaylandWindow *window, |
25 | struct ::ivi_controller_surface *iviControllerSurface); |
26 | ~QWaylandIviSurface() override; |
27 | |
28 | void applyConfigure() override; |
29 | |
30 | std::any surfaceRole() const override { return ivi_surface::object(); }; |
31 | |
32 | private: |
33 | void createExtendedSurface(QWaylandWindow *window); |
34 | void ivi_surface_configure(int32_t width, int32_t height) override; |
35 | void ivi_controller_surface_visibility(int32_t visibility) override; |
36 | |
37 | QWaylandWindow *m_window = nullptr; |
38 | QWaylandExtendedSurface *m_extendedWindow = nullptr; |
39 | QSize m_pendingSize = {0, 0}; |
40 | }; |
41 | |
42 | } |
43 | |
44 | QT_END_NAMESPACE |
45 | |
46 | #endif // QWAYLANDIVISURFACE_H |
47 | |