aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-05-17 08:14:34 -0400
committerGitHub <noreply@github.com>2018-05-17 08:14:34 -0400
commit98088e78df054553ec846043ee913d0dcf39de16 (patch)
tree7eefa8031fff33f5a518dd0d816d30750a937517 /include
parentc74f5b11382112f28adad886ad993c77276b9208 (diff)
parent303650746360e69ea880a7f6b6df944d343dee79 (diff)
Merge pull request #977 from emersion/split-xdg-shell
Split xdg-shell into multiple files
Diffstat (limited to 'include')
-rw-r--r--include/types/wlr_xdg_shell.h45
-rw-r--r--include/types/wlr_xdg_shell_v6.h36
2 files changed, 63 insertions, 18 deletions
diff --git a/include/types/wlr_xdg_shell.h b/include/types/wlr_xdg_shell.h
new file mode 100644
index 00000000..74f13bbe
--- /dev/null
+++ b/include/types/wlr_xdg_shell.h
@@ -0,0 +1,45 @@
+#ifndef TYPES_WLR_XDG_SHELL_H
+#define TYPES_WLR_XDG_SHELL_H
+
+#include <wayland-server.h>
+#include <wlr/types/wlr_xdg_shell.h>
+#include "xdg-shell-protocol.h"
+
+struct wlr_xdg_positioner_resource {
+ struct wl_resource *resource;
+ struct wlr_xdg_positioner attrs;
+};
+
+#define XDG_TOPLEVEL_ROLE "xdg_toplevel"
+#define XDG_POPUP_ROLE "xdg_popup"
+
+uint32_t schedule_xdg_surface_configure(struct wlr_xdg_surface *surface);
+struct wlr_xdg_surface *create_xdg_surface(
+ struct wlr_xdg_client *client, struct wlr_surface *surface,
+ uint32_t id);
+void unmap_xdg_surface(struct wlr_xdg_surface *surface);
+void destroy_xdg_surface(struct wlr_xdg_surface *surface);
+
+void create_xdg_positioner(struct wlr_xdg_client *client, uint32_t id);
+struct wlr_xdg_positioner_resource *get_xdg_positioner_from_resource(
+ struct wl_resource *resource);
+
+void create_xdg_popup(struct wlr_xdg_surface *xdg_surface,
+ struct wlr_xdg_surface *parent,
+ struct wlr_xdg_positioner_resource *positioner, int32_t id);
+void handle_xdg_surface_popup_committed(struct wlr_xdg_surface *surface);
+struct wlr_xdg_popup_grab *get_xdg_shell_popup_grab_from_seat(
+ struct wlr_xdg_shell *shell, struct wlr_seat *seat);
+void destroy_xdg_popup(struct wlr_xdg_surface *surface);
+
+void create_xdg_toplevel(struct wlr_xdg_surface *xdg_surface,
+ uint32_t id);
+void handle_xdg_surface_toplevel_committed(struct wlr_xdg_surface *surface);
+void send_xdg_toplevel_configure(struct wlr_xdg_surface *surface,
+ struct wlr_xdg_surface_configure *configure);
+void handle_xdg_toplevel_ack_configure(struct wlr_xdg_surface *surface,
+ struct wlr_xdg_surface_configure *configure);
+bool compare_xdg_surface_toplevel_state(struct wlr_xdg_toplevel *state);
+void destroy_xdg_toplevel(struct wlr_xdg_surface *surface);
+
+#endif
diff --git a/include/types/wlr_xdg_shell_v6.h b/include/types/wlr_xdg_shell_v6.h
index 6c440529..b5325998 100644
--- a/include/types/wlr_xdg_shell_v6.h
+++ b/include/types/wlr_xdg_shell_v6.h
@@ -10,36 +10,36 @@ struct wlr_xdg_positioner_v6_resource {
struct wlr_xdg_positioner_v6 attrs;
};
-#define XDG_TOPLEVEL_ROLE "xdg_toplevel_v6"
-#define XDG_POPUP_ROLE "xdg_popup_v6"
+#define XDG_TOPLEVEL_V6_ROLE "xdg_toplevel_v6"
+#define XDG_POPUP_V6_ROLE "xdg_popup_v6"
-uint32_t xdg_surface_v6_schedule_configure(struct wlr_xdg_surface_v6 *surface);
-struct wlr_xdg_surface_v6 *xdg_surface_v6_create(
+uint32_t schedule_xdg_surface_v6_configure(struct wlr_xdg_surface_v6 *surface);
+struct wlr_xdg_surface_v6 *create_xdg_surface_v6(
struct wlr_xdg_client_v6 *client, struct wlr_surface *surface,
uint32_t id);
-void xdg_surface_unmap(struct wlr_xdg_surface_v6 *surface);
-void xdg_surface_destroy(struct wlr_xdg_surface_v6 *surface);
+void unmap_xdg_surface_v6(struct wlr_xdg_surface_v6 *surface);
+void destroy_xdg_surface_v6(struct wlr_xdg_surface_v6 *surface);
-void xdg_positioner_v6_create(struct wlr_xdg_client_v6 *client, uint32_t id);
-struct wlr_xdg_positioner_v6_resource *xdg_positioner_from_resource(
+void create_xdg_positioner_v6(struct wlr_xdg_client_v6 *client, uint32_t id);
+struct wlr_xdg_positioner_v6_resource *get_xdg_positioner_v6_from_resource(
struct wl_resource *resource);
-void xdg_popup_v6_create(struct wlr_xdg_surface_v6 *xdg_surface,
+void create_xdg_popup_v6(struct wlr_xdg_surface_v6 *xdg_surface,
struct wlr_xdg_surface_v6 *parent,
struct wlr_xdg_positioner_v6_resource *positioner, int32_t id);
-void xdg_surface_v6_popup_committed(struct wlr_xdg_surface_v6 *surface);
-struct wlr_xdg_popup_grab_v6 *xdg_shell_popup_grab_from_seat(
+void handle_xdg_surface_v6_popup_committed(struct wlr_xdg_surface_v6 *surface);
+struct wlr_xdg_popup_grab_v6 *get_xdg_shell_v6_popup_grab_from_seat(
struct wlr_xdg_shell_v6 *shell, struct wlr_seat *seat);
-void xdg_popup_destroy(struct wlr_xdg_surface_v6 *surface);
+void destroy_xdg_popup_v6(struct wlr_xdg_surface_v6 *surface);
-void xdg_toplevel_v6_create(struct wlr_xdg_surface_v6 *xdg_surface,
+void create_xdg_toplevel_v6(struct wlr_xdg_surface_v6 *xdg_surface,
uint32_t id);
-void xdg_surface_v6_toplevel_committed(struct wlr_xdg_surface_v6 *surface);
-void xdg_toplevel_v6_send_configure(struct wlr_xdg_surface_v6 *surface,
+void handle_xdg_surface_v6_toplevel_committed(struct wlr_xdg_surface_v6 *surface);
+void send_xdg_toplevel_v6_configure(struct wlr_xdg_surface_v6 *surface,
struct wlr_xdg_surface_v6_configure *configure);
-void xdg_toplevel_v6_ack_configure(struct wlr_xdg_surface_v6 *surface,
+void handle_xdg_toplevel_v6_ack_configure(struct wlr_xdg_surface_v6 *surface,
struct wlr_xdg_surface_v6_configure *configure);
-bool xdg_surface_v6_toplevel_state_compare(struct wlr_xdg_toplevel_v6 *state);
-void xdg_toplevel_destroy(struct wlr_xdg_surface_v6 *surface);
+bool compare_xdg_surface_v6_toplevel_state(struct wlr_xdg_toplevel_v6 *state);
+void destroy_xdg_toplevel_v6(struct wlr_xdg_surface_v6 *surface);
#endif