surface: Drop gdk_surface_show

No longer used.
This commit is contained in:
Matthias Clasen 2020-03-11 16:16:33 -04:00
parent 4dc27ee4a6
commit 8b57092958
2 changed files with 0 additions and 61 deletions

View File

@ -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 *
*****************************************/

View File

@ -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 its 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