diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2022-06-16 21:07:02 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2022-06-16 21:07:02 +0300 |
commit | c27a395d8cd8b58b3155cfdc26ae35198fbcdb14 (patch) | |
tree | 665b37d674c62451ddd954c6012bab9d9ec4a862 /intern/ghost/intern/GHOST_WindowWayland.h | |
parent | 29d24182b76be06b11c66138cb26cd63da0f9130 (diff) | |
parent | 209bf7780e7c005650482fa843062864f91845af (diff) |
Merge branch 'master' into asset-greasepencil
Diffstat (limited to 'intern/ghost/intern/GHOST_WindowWayland.h')
-rw-r--r-- | intern/ghost/intern/GHOST_WindowWayland.h | 44 |
1 files changed, 25 insertions, 19 deletions
diff --git a/intern/ghost/intern/GHOST_WindowWayland.h b/intern/ghost/intern/GHOST_WindowWayland.h index d5dd123014b..b6d9fa04079 100644 --- a/intern/ghost/intern/GHOST_WindowWayland.h +++ b/intern/ghost/intern/GHOST_WindowWayland.h @@ -17,7 +17,6 @@ class GHOST_SystemWayland; struct output_t; struct window_t; -struct wl_surface; class GHOST_WindowWayland : public GHOST_Window { public: @@ -40,25 +39,8 @@ class GHOST_WindowWayland : public GHOST_Window { uint16_t getDPIHint() override; - GHOST_TSuccess close(); - - GHOST_TSuccess activate(); - - GHOST_TSuccess deactivate(); - - GHOST_TSuccess notify_size(); + /* Ghost API */ - wl_surface *surface() const; - - const std::vector<output_t *> &outputs() const; - - std::unordered_set<const output_t *> &outputs_active(); - - uint16_t &dpi(); - - int &scale(); - - protected: GHOST_TSuccess setWindowCursorGrab(GHOST_TGrabCursorMode mode) override; GHOST_TSuccess setWindowCursorShape(GHOST_TStandardCursor shape) override; @@ -109,6 +91,30 @@ class GHOST_WindowWayland : public GHOST_Window { void setOpaque() const; #endif + /* WAYLAND utility functions. */ + + GHOST_TSuccess close(); + + GHOST_TSuccess activate(); + + GHOST_TSuccess deactivate(); + + GHOST_TSuccess notify_size(); + + struct wl_surface *surface() const; + + output_t *output_find_by_wl(struct wl_output *output); + + const std::vector<output_t *> &outputs(); + + bool outputs_enter(output_t *reg_output); + bool outputs_leave(output_t *reg_output); + bool outputs_changed_update_scale(); + + uint16_t dpi(); + + int scale(); + private: GHOST_SystemWayland *m_system; struct window_t *w; |