[gtk/gdk-api-cleanups: 17/21] Rename gdk_device_get_position_double



commit 03eb455c9345054c456df9ef0416bee1c49dd1be
Author: Matthias Clasen <mclasen redhat com>
Date:   Mon Mar 25 20:30:15 2019 -0400

    Rename gdk_device_get_position_double
    
    We can drop the double suffix now.

 docs/reference/gdk/gdk4-sections.txt | 2 +-
 gdk/gdkdevice.c                      | 8 ++++----
 gdk/gdkdevice.h                      | 6 +++---
 gdk/win32/gdkdrag-win32.c            | 2 +-
 gdk/x11/gdkdrag-x11.c                | 2 +-
 gtk/gtknotebook.c                    | 4 ++--
 gtk/gtkwidget.c                      | 6 +++---
 gtk/gtkwindow.c                      | 4 ++--
 8 files changed, 17 insertions(+), 17 deletions(-)
---
diff --git a/docs/reference/gdk/gdk4-sections.txt b/docs/reference/gdk/gdk4-sections.txt
index 5e91f9c21e..0e52bcafdc 100644
--- a/docs/reference/gdk/gdk4-sections.txt
+++ b/docs/reference/gdk/gdk4-sections.txt
@@ -509,7 +509,7 @@ gdk_device_ungrab
 
 <SUBSECTION>
 gdk_device_get_state
-gdk_device_get_position_double
+gdk_device_get_position
 gdk_device_get_surface_at_position
 gdk_device_get_surface_at_position_double
 gdk_device_get_history
diff --git a/gdk/gdkdevice.c b/gdk/gdkdevice.c
index 2044becfe5..ec46684e12 100644
--- a/gdk/gdkdevice.c
+++ b/gdk/gdkdevice.c
@@ -529,7 +529,7 @@ gdk_device_get_state (GdkDevice       *device,
 }
 
 /**
- * gdk_device_get_position_double:
+ * gdk_device_get_position:
  * @device: pointer device to query status about.
  * @x: (out) (allow-none): location to store root window X coordinate of @device, or %NULL.
  * @y: (out) (allow-none): location to store root window Y coordinate of @device, or %NULL.
@@ -540,9 +540,9 @@ gdk_device_get_state (GdkDevice       *device,
  * unless there is an ongoing grab on them. See gdk_device_grab().
  **/
 void
-gdk_device_get_position_double (GdkDevice        *device,
-                                gdouble          *x,
-                                gdouble          *y)
+gdk_device_get_position (GdkDevice *device,
+                         double    *x,
+                         double    *y)
 {
   GdkDisplay *display;
   gdouble tmp_x, tmp_y;
diff --git a/gdk/gdkdevice.h b/gdk/gdkdevice.h
index aa07f3f9b1..d86179b638 100644
--- a/gdk/gdkdevice.h
+++ b/gdk/gdkdevice.h
@@ -173,9 +173,9 @@ GdkSurface *
                                   gint              *win_x,
                                   gint              *win_y);
 GDK_AVAILABLE_IN_ALL
-void     gdk_device_get_position_double (GdkDevice         *device,
-                                         gdouble           *x,
-                                         gdouble           *y);
+void     gdk_device_get_position (GdkDevice *device,
+                                  double    *x,
+                                  double    *y);
 GDK_AVAILABLE_IN_ALL
 GdkSurface *
          gdk_device_get_surface_at_position_double
diff --git a/gdk/win32/gdkdrag-win32.c b/gdk/win32/gdkdrag-win32.c
index 5583ac9421..25723451e2 100644
--- a/gdk/win32/gdkdrag-win32.c
+++ b/gdk/win32/gdkdrag-win32.c
@@ -1732,7 +1732,7 @@ _gdk_win32_surface_drag_begin (GdkSurface         *surface,
 
   GDK_NOTE (DND, g_print ("_gdk_win32_surface_drag_begin\n"));
 
-  gdk_device_get_position_double (device, &px, &px);
+  gdk_device_get_position (device, &px, &px);
   x_root = round (px) + dx;
   y_root = round (py) + dy;
 
diff --git a/gdk/x11/gdkdrag-x11.c b/gdk/x11/gdkdrag-x11.c
index 4305bdaf13..2a7e705c23 100644
--- a/gdk/x11/gdkdrag-x11.c
+++ b/gdk/x11/gdkdrag-x11.c
@@ -2098,7 +2098,7 @@ _gdk_x11_surface_drag_begin (GdkSurface         *surface,
 
   precache_target_list (drag);
 
-  gdk_device_get_position_double (device, &px, &py);
+  gdk_device_get_position (device, &px, &py);
   x_root = round (px) + dx;
   y_root = round (py) + dy;
 
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 4afc889aee..868bbfa956 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -3139,7 +3139,7 @@ gtk_notebook_drag_end (GtkWidget      *widget,
       GtkNotebook *dest_notebook = NULL;
       double x, y;
 
-      gdk_device_get_position_double (gdk_drag_get_device (drag), &x, &y);
+      gdk_device_get_position (gdk_drag_get_device (drag), &x, &y);
       g_signal_emit (notebook, notebook_signals[CREATE_WINDOW], 0,
                      priv->detached_tab->child, round (x), round (y), &dest_notebook);
 
@@ -3188,7 +3188,7 @@ gtk_notebook_drag_failed (GtkWidget      *widget,
       GtkNotebook *dest_notebook = NULL;
       double x, y;
 
-      gdk_device_get_position_double (gdk_drag_get_device (drag), &x, &y);
+      gdk_device_get_position (gdk_drag_get_device (drag), &x, &y);
 
       g_signal_emit (notebook, notebook_signals[CREATE_WINDOW], 0,
                      priv->detached_tab->child, round (x), round (y), &dest_notebook);
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index 7eaf9ade9b..f23e28ea01 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -8642,9 +8642,9 @@ synth_crossing (GtkWidget       *widget,
   event->any.send_event = TRUE;
   event->crossing.child_surface = g_object_ref (surface);
   event->crossing.time = GDK_CURRENT_TIME;
-  gdk_device_get_position_double (device,
-                                  &event->crossing.x_root,
-                                  &event->crossing.y_root);
+  gdk_device_get_position (device,
+                           &event->crossing.x_root,
+                           &event->crossing.y_root);
   gdk_surface_get_device_position (surface,
                                    device,
                                    &event->crossing.x,
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 71be75328a..8e3024e095 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -7265,7 +7265,7 @@ get_monitor_containing_pointer (GtkWindow *window)
   GdkDevice *pointer;
 
   pointer = gdk_seat_get_pointer (gdk_display_get_default_seat (priv->display));
-  gdk_device_get_position_double (pointer, &px, &py);
+  gdk_device_get_position (pointer, &px, &py);
 
   return gdk_display_get_monitor_at_point (priv->display, round (px), round (py));
 }
@@ -7432,7 +7432,7 @@ gtk_window_compute_configure_request (GtkWindow    *window,
 
             pointer = gdk_seat_get_pointer (gdk_display_get_default_seat (priv->display));
 
-            gdk_device_get_position_double (pointer, &px, &py);
+            gdk_device_get_position (pointer, &px, &py);
             monitor = gdk_display_get_monitor_at_point (priv->display, round (px), round (py));
 
             x = round (px) - w / 2;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]