summaryrefslogtreecommitdiffstats
path: root/src/gui_riscos.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-01-08 21:45:39 +0000
committerBram Moolenaar <Bram@vim.org>2005-01-08 21:45:39 +0000
commit9588a0f72bc1f72962e3e327d29775d3a970e579 (patch)
tree239a6a28f7f033daafca7b95ca8b10150de8328f /src/gui_riscos.c
parente49b69a091e72ce1b1a5e7091ebf2ebddd795e6d (diff)
updated for version 7.0035
Diffstat (limited to 'src/gui_riscos.c')
-rw-r--r--src/gui_riscos.c30
1 files changed, 8 insertions, 22 deletions
diff --git a/src/gui_riscos.c b/src/gui_riscos.c
index 07cbc75435..2c40514fd6 100644
--- a/src/gui_riscos.c
+++ b/src/gui_riscos.c
@@ -3014,40 +3014,26 @@ gui_mch_set_scrollbar_colors(scrollbar_T *sb)
}
/*
- * Get current x mouse coordinate in text window.
+ * Get current mouse coordinates in text window.
* Note: (0,0) is the bottom left corner, positive y is UP.
- * Return -1 when unknown.
*/
- int
-gui_mch_get_mouse_x()
+ void
+gui_mch_getmouse(x, y)
+ int *x;
+ int *y;
{
int left;
- int block[10];
-
- block[0] = gui.window_handle;
- swi(Wimp_GetWindowState, 0, block);
- left = block[1];
-
- swi(Wimp_GetPointerInfo, 0, block);
- return block[0] - left;
-}
-
-/*
- * Get current y mouse coordinate in text window.
- * Return -1 when unknown.
- */
- int
-gui_mch_get_mouse_y()
-{
int top;
int block[10];
block[0] = gui.window_handle;
swi(Wimp_GetWindowState, 0, block);
+ left = block[1];
top = block[4];
swi(Wimp_GetPointerInfo, 0, block);
- return top - block[1];
+ *x = block[0] - left;
+ *y = top - block[1];
}
/* MouseTo(x, y) */