aboutsummaryrefslogtreecommitdiff
path: root/include/rootston
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2018-09-27 10:25:59 +0200
committeremersion <contact@emersion.fr>2018-09-27 10:25:59 +0200
commitdac4f8e19ffd19dfeee2c65270476a52c13d0f8f (patch)
tree2d268b14381f282afc58e1722e5ad61d1c19afda /include/rootston
parent31cc2fa4f9eae8f6c884b35c500aef4225b3f9ef (diff)
pointer-constraints: refactoring
* Rename the constraint_create signal to new_constraint for consistency * Move the constraint_destroy signal to the constraint itself * Use rotate_child_position instead of duplicating logic * Fix inert constraint resource handling * Style fixes
Diffstat (limited to 'include/rootston')
-rw-r--r--include/rootston/desktop.h3
-rw-r--r--include/rootston/output.h3
-rw-r--r--include/rootston/seat.h6
3 files changed, 10 insertions, 2 deletions
diff --git a/include/rootston/desktop.h b/include/rootston/desktop.h
index dac694d1..90851a17 100644
--- a/include/rootston/desktop.h
+++ b/include/rootston/desktop.h
@@ -68,8 +68,7 @@ struct roots_desktop {
struct wl_listener input_inhibit_activate;
struct wl_listener input_inhibit_deactivate;
struct wl_listener virtual_keyboard_new;
- struct wl_listener constraint_create;
- struct wl_listener constraint_destroy;
+ struct wl_listener pointer_constraint;
#ifdef WLR_HAS_XWAYLAND
struct wlr_xwayland *xwayland;
diff --git a/include/rootston/output.h b/include/rootston/output.h
index f78ee81d..69bc5126 100644
--- a/include/rootston/output.h
+++ b/include/rootston/output.h
@@ -28,6 +28,9 @@ struct roots_output {
struct wl_listener damage_destroy;
};
+void rotate_child_position(double *sx, double *sy, double sw, double sh,
+ double pw, double ph, float rotation);
+
void handle_new_output(struct wl_listener *listener, void *data);
struct roots_view;
diff --git a/include/rootston/seat.h b/include/rootston/seat.h
index a3192d26..1248918a 100644
--- a/include/rootston/seat.h
+++ b/include/rootston/seat.h
@@ -122,6 +122,12 @@ struct roots_tablet_tool {
struct wl_listener tablet_destroy;
};
+struct roots_pointer_constraint {
+ struct wlr_pointer_constraint_v1 *constraint;
+
+ struct wl_listener destroy;
+};
+
struct roots_seat *roots_seat_create(struct roots_input *input, char *name);
void roots_seat_destroy(struct roots_seat *seat);