[gtk/present-toplevel-2: 70/70] Drop gdk_surface_show and gdk_surface_resize



commit 5117f71a9c45a24b90db761d0183ac12e973e4f7
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue Mar 3 16:03:39 2020 -0800

    Drop gdk_surface_show and gdk_surface_resize
    
    We can now use GdkDragIcon api for the last cases
    where this was used.

 gdk/gdkinternals.h |  1 +
 gdk/gdksurface.c   | 39 ---------------------------------------
 gdk/gdksurface.h   |  6 ------
 3 files changed, 1 insertion(+), 45 deletions(-)
---
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index 4702f7ec9e..48c0c63c1b 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -182,6 +182,7 @@ void gdk_surface_get_unscaled_size (GdkSurface *surface,
                                     int *unscaled_height);
 gboolean gdk_surface_handle_event (GdkEvent       *event);
 
+void gdk_surface_show (GdkSurface *surface);
 
 /*****************************************
  * Interfaces provided by windowing code *
diff --git a/gdk/gdksurface.c b/gdk/gdksurface.c
index 9f968384f3..eba1b1fc20 100644
--- a/gdk/gdksurface.c
+++ b/gdk/gdksurface.c
@@ -1893,28 +1893,9 @@ gdk_surface_lower_internal (GdkSurface *surface)
   GDK_SURFACE_GET_CLASS (surface)->lower (surface);
 }
 
-/**
- * gdk_surface_show:
- * @surface: a #GdkSurface
- *
- * Like gdk_surface_show_unraised(), but also raises the surface to the
- * top of the surface stack (moves the surface to the front of the
- * Z-order).
- *
- * This function maps a surface so it’s visible onscreen. Its opposite
- * is gdk_surface_hide().
- *
- * This function may not be used on a #GdkSurface with the surface type
- * GTK_SURFACE_POPUP.
- *
- * When implementing a #GtkWidget, you should call this function on the widget's
- * #GdkSurface as part of the “map” method.
- */
 void
 gdk_surface_show (GdkSurface *surface)
 {
-  g_return_if_fail (surface->surface_type != GDK_SURFACE_POPUP);
-
   gdk_surface_show_internal (surface, TRUE);
 }
 
@@ -1983,26 +1964,6 @@ G_GNUC_END_IGNORE_DEPRECATIONS
   surface->y = 0;
 }
 
-/**
- * gdk_surface_resize:
- * @surface: a #GdkSurface
- * @width: new width of the surface
- * @height: new height of the surface
- *
- * Resizes @surface; for toplevel surfaces, asks the window manager to resize
- * the surface. The window manager may not allow the resize. When using GTK,
- * use gtk_window_resize() instead of this low-level GDK function.
- *
- * Surfaces may not be resized below 1x1.
- */
-void
-gdk_surface_resize (GdkSurface *surface,
-                    gint       width,
-                    gint       height)
-{
-  GDK_SURFACE_GET_CLASS (surface)->toplevel_resize (surface, width, height);
-}
-
 static gboolean
 gdk_popup_surface_present (GdkPopup       *popup,
                            int             width,
diff --git a/gdk/gdksurface.h b/gdk/gdksurface.h
index 0bde1ffd04..1aaa996eed 100644
--- a/gdk/gdksurface.h
+++ b/gdk/gdksurface.h
@@ -353,13 +353,7 @@ gboolean      gdk_surface_is_destroyed          (GdkSurface     *surface);
 GDK_AVAILABLE_IN_ALL
 GdkDisplay *  gdk_surface_get_display           (GdkSurface     *surface);
 GDK_AVAILABLE_IN_ALL
-void          gdk_surface_show                  (GdkSurface     *surface);
-GDK_AVAILABLE_IN_ALL
 void          gdk_surface_hide                  (GdkSurface     *surface);
-GDK_AVAILABLE_IN_ALL
-void          gdk_surface_resize                (GdkSurface     *surface,
-                                                 gint           width,
-                                                 gint           height);
 
 GDK_AVAILABLE_IN_ALL
 void          gdk_surface_set_input_region      (GdkSurface     *surface,


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