input: Add weston_pointer_clamp function to ensure pointer visible
This refactors the code out from clip_pointer_motion into a function of
its own which can then be used elsewhere to clamp the pointer
coordinates to the range of the outputs.
This change also makes the caller of clip_pointer_motion use this new
function.
diff --git a/src/compositor.h b/src/compositor.h
index 3206e45..45a14d6 100644
--- a/src/compositor.h
+++ b/src/compositor.h
@@ -345,6 +345,9 @@
struct weston_pointer_grab *grab);
void
weston_pointer_end_grab(struct weston_pointer *pointer);
+void
+weston_pointer_clamp(struct weston_pointer *pointer,
+ wl_fixed_t *fx, wl_fixed_t *fy);
struct weston_keyboard *
weston_keyboard_create(void);