summaryrefslogtreecommitdiff
path: root/riscos/mouse.h
diff options
context:
space:
mode:
authorSteve Fryatt <stevef@netsurf-browser.org>2013-09-08 11:55:21 +0100
committerSteve Fryatt <stevef@netsurf-browser.org>2013-09-08 11:55:21 +0100
commita00e0f91c7ccb27108cc396ca8afa3207935de4c (patch)
treedfe47712132b8f26f46fe319f3222b44c5e2e060 /riscos/mouse.h
parente87596ad1f7755c50f7a00edc85e66908ad1ba10 (diff)
downloadnetsurf-a00e0f91c7ccb27108cc396ca8afa3207935de4c.tar.gz
netsurf-a00e0f91c7ccb27108cc396ca8afa3207935de4c.tar.bz2
Move all mouse tracking into ro_mouse module.
Add Pointer Entering Window events to wimp_event module and add handlers to all modules requiring mouse tracking. Updated: Treeview, URL Complete, History and GUI Window. Delete all handling for Pointer Entering/Leaving from ro_gui.
Diffstat (limited to 'riscos/mouse.h')
-rw-r--r--riscos/mouse.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/riscos/mouse.h b/riscos/mouse.h
index 623c6dfaa..26fb72e5b 100644
--- a/riscos/mouse.h
+++ b/riscos/mouse.h
@@ -65,5 +65,30 @@ void ro_mouse_drag_start(void (*drag_end)(wimp_dragged *dragged, void *data),
void ro_mouse_drag_end(wimp_dragged *dragged);
+
+/**
+ * Start tracking the mouse in a window, providing a function to be called on
+ * null polls and optionally one to be called when it leaves the window.
+ *
+ * \param *drag_end Callback for when the pointer leaves the window, or
+ * NULL for none.
+ * \param *drag_track Callback for mouse tracking while the pointer remains
+ * in the window, or NULL for none.
+ * \param *data Data to be passed to the callback functions, or NULL.
+ */
+
+void ro_mouse_track_start(void (*poll_end)(wimp_leaving *leaving, void *data),
+ void (*poll_track)(wimp_pointer *pointer, void *data),
+ void *data);
+
+/**
+ * Process Wimp_PointerLeaving events by terminating an active mouse track and
+ * passing the details on to any registered event handler.
+ *
+ * \param *leaving The Wimp_PointerLeaving data block.
+ */
+
+void ro_mouse_pointer_leaving_window(wimp_leaving *leaving);
+
#endif