diff options
Diffstat (limited to 'wayland.h')
| -rw-r--r-- | wayland.h | 43 |
1 files changed, 10 insertions, 33 deletions
@@ -9,22 +9,16 @@ #include <xkbcommon/xkbcommon.h> /* Wayland protocols */ +#include <fractional-scale-v1.h> #include <presentation-time.h> #include <primary-selection-unstable-v1.h> #include <text-input-unstable-v3.h> +#include <viewporter.h> +#include <xdg-activation-v1.h> #include <xdg-decoration-unstable-v1.h> #include <xdg-output-unstable-v1.h> #include <xdg-shell.h> -#if defined(HAVE_XDG_ACTIVATION) - #include <xdg-activation-v1.h> -#endif - -#if defined(HAVE_FRACTIONAL_SCALE) - #include <viewporter.h> - #include <fractional-scale-v1.h> -#endif - #include <fcft/fcft.h> #include <tllist.h> @@ -57,9 +51,7 @@ enum touch_state { struct wayl_surface { struct wl_surface *surf; -#if defined(HAVE_FRACTIONAL_SCALE) struct wp_viewport *viewport; -#endif }; struct wayl_sub_surface { @@ -160,9 +152,7 @@ struct seat { struct wl_cursor *cursor; /* Server-side cursor */ -#if defined(HAVE_CURSOR_SHAPE) struct wp_cursor_shape_device_v1 *shape_device; -#endif float scale; bool hidden; @@ -345,7 +335,6 @@ struct wl_url { enum csd_mode {CSD_UNKNOWN, CSD_NO, CSD_YES}; -#if defined(HAVE_XDG_ACTIVATION) typedef void (*activation_token_cb_t)(const char *token, void *data); /* @@ -359,7 +348,6 @@ struct xdg_activation_token_context { activation_token_cb_t cb; /* User provided callback */ void *cb_data; /* Callback user pointer */ }; -#endif struct wayland; struct wl_window { @@ -367,15 +355,12 @@ struct wl_window { struct wayl_surface surface; struct xdg_surface *xdg_surface; struct xdg_toplevel *xdg_toplevel; -#if defined(HAVE_XDG_ACTIVATION) + struct wp_fractional_scale_v1 *fractional_scale; + tll(struct xdg_activation_token_context *) xdg_tokens; bool urgency_token_is_pending; -#endif -#if defined(HAVE_FRACTIONAL_SCALE) - struct wp_fractional_scale_v1 *fractional_scale; -#endif - bool unmapped; + bool unmapped; float scale; struct zxdg_toplevel_decoration_v1 *xdg_toplevel_decoration; @@ -451,27 +436,21 @@ struct wayland { struct wl_data_device_manager *data_device_manager; struct zwp_primary_selection_device_manager_v1 *primary_selection_device_manager; -#if defined(HAVE_XDG_ACTIVATION) struct xdg_activation_v1 *xdg_activation; -#endif -#if defined(HAVE_CURSOR_SHAPE) + struct wp_viewporter *viewporter; + struct wp_fractional_scale_manager_v1 *fractional_scale_manager; + struct wp_cursor_shape_manager_v1 *cursor_shape_manager; -#endif bool presentation_timings; struct wp_presentation *presentation; uint32_t presentation_clock_id; - + #if defined(FOOT_IME_ENABLED) && FOOT_IME_ENABLED struct zwp_text_input_manager_v3 *text_input_manager; #endif -#if defined(HAVE_FRACTIONAL_SCALE) - struct wp_viewporter *viewporter; - struct wp_fractional_scale_manager_v1 *fractional_scale_manager; -#endif - bool have_argb8888; tll(struct monitor) monitors; /* All available outputs */ tll(struct seat) seats; @@ -515,8 +494,6 @@ bool wayl_win_subsurface_new_with_custom_parent( struct wayl_sub_surface *surf, bool allow_pointer_input); void wayl_win_subsurface_destroy(struct wayl_sub_surface *surf); -#if defined(HAVE_XDG_ACTIVATION) bool wayl_get_activation_token( struct wayland *wayl, struct seat *seat, uint32_t serial, struct wl_window *win, activation_token_cb_t cb, void *cb_data); -#endif |
