Mercurial > dwindows
comparison gtk/dw.c @ 1122:e52c710e6d08
Minor change to allow dw_pointer_query_pos() to take NULL paramaters on GTK.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Fri, 26 Aug 2011 18:47:39 +0000 |
parents | fb92778105b2 |
children | 38856b5bb72e |
comparison
equal
deleted
inserted
replaced
1121:fb92778105b2 | 1122:e52c710e6d08 |
---|---|
3887 int gx, gy; | 3887 int gx, gy; |
3888 int _locked_by_me = FALSE; | 3888 int _locked_by_me = FALSE; |
3889 | 3889 |
3890 DW_MUTEX_LOCK; | 3890 DW_MUTEX_LOCK; |
3891 gdk_window_get_pointer (GDK_ROOT_PARENT(), &gx, &gy, &state); | 3891 gdk_window_get_pointer (GDK_ROOT_PARENT(), &gx, &gy, &state); |
3892 *x = gx; | 3892 if(x) |
3893 *y = gy; | 3893 *x = gx; |
3894 if(y) | |
3895 *y = gy; | |
3896 printf("x %d y %d\n", gx, gy); | |
3894 DW_MUTEX_UNLOCK; | 3897 DW_MUTEX_UNLOCK; |
3895 } | 3898 } |
3896 | 3899 |
3897 /* | 3900 /* |
3898 * Sets the X and Y coordinates of the mouse pointer. | 3901 * Sets the X and Y coordinates of the mouse pointer. |