[gtk/present-toplevel-2: 69/83] surface: Drop gdk_surface_show



commit 588fa497ab7eaf22401df38e803ee8d2fe2ba3e6
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Mar 11 16:16:33 2020 -0400

    surface: Drop gdk_surface_show
    
    No longer used.

 gdk/gdkinternals.h |  2 --
 gdk/gdksurface.c   | 59 ------------------------------------------------------
 2 files changed, 61 deletions(-)
---
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index 48c0c63c1b..3c6271a6e2 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -182,8 +182,6 @@ 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 746a1f493b..48bac4433e 100644
--- a/gdk/gdksurface.c
+++ b/gdk/gdksurface.c
@@ -1653,12 +1653,6 @@ gdk_surface_get_device_position (GdkSurface       *surface,
     *mask = tmp_mask;
 }
 
-static void
-gdk_surface_raise_internal (GdkSurface *surface)
-{
-  GDK_SURFACE_GET_CLASS (surface)->raise (surface);
-}
-
 /* Returns TRUE If the native surface was mapped or unmapped */
 static gboolean
 set_viewable (GdkSurface *w,
@@ -1678,59 +1672,6 @@ _gdk_surface_update_viewable (GdkSurface *surface)
   return set_viewable (surface, GDK_SURFACE_IS_MAPPED (surface));
 }
 
-static void
-gdk_surface_show_internal (GdkSurface *surface, gboolean raise)
-{
-  gboolean was_mapped;
-  gboolean did_show;
-
-  g_return_if_fail (GDK_IS_SURFACE (surface));
-
-  if (surface->destroyed)
-    return;
-
-  was_mapped = GDK_SURFACE_IS_MAPPED (surface);
-
-  if (raise)
-    gdk_surface_raise_internal (surface);
-
-  if (!was_mapped)
-    gdk_synthesize_surface_state (surface, GDK_SURFACE_STATE_WITHDRAWN, 0);
-
-  did_show = _gdk_surface_update_viewable (surface);
-
-  GDK_SURFACE_GET_CLASS (surface)->show (surface, !did_show ? was_mapped : TRUE);
-
-  if (!was_mapped)
-    {
-      if (gdk_surface_is_viewable (surface))
-        gdk_surface_invalidate_rect (surface, NULL);
-    }
-}
-
-/**
- * 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)
-{
-  gdk_surface_show_internal (surface, TRUE);
-}
-
 /**
  * gdk_surface_hide:
  * @surface: a #GdkSurface


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