diff options
author | Matthias Clasen <mclasen@redhat.com> | 2019-03-23 09:35:14 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2019-03-26 19:18:40 -0400 |
commit | 2aa7075d4c504c0bcd1b7c771cad788a4ca93520 (patch) | |
tree | 48b2ab62069fdec4016acdd925568d16fadb697e | |
parent | 4a8595fa1bd58b47bb777e6de4d670cc29d9e1e2 (diff) | |
download | gtk+-2aa7075d4c504c0bcd1b7c771cad788a4ca93520.tar.gz |
surface: Simplify some code
Fold gdk_surface_process_updates_recurse into its
only caller. There is no recursion here anymore.
-rw-r--r-- | gdk/gdksurface.c | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/gdk/gdksurface.c b/gdk/gdksurface.c index 79609239a8..d230d97c6b 100644 --- a/gdk/gdksurface.c +++ b/gdk/gdksurface.c @@ -1111,22 +1111,6 @@ gdk_surface_schedule_update (GdkSurface *surface) } static void -gdk_surface_process_updates_recurse (GdkSurface *surface, - cairo_region_t *expose_region) -{ - gboolean handled; - - if (surface->destroyed) - return; - - /* Paint the surface before the children, clipped to the surface region */ - g_signal_emit (surface, signals[RENDER], 0, expose_region, &handled); -} - -/* Process and remove any invalid area on the native surface by creating - * expose events for the surface and all non-native descendants. - */ -static void gdk_surface_process_updates_internal (GdkSurface *surface) { /* Ensure the surface lives while updating it */ @@ -1148,10 +1132,11 @@ gdk_surface_process_updates_internal (GdkSurface *surface) if (gdk_surface_is_viewable (surface)) { cairo_region_t *expose_region; + gboolean handled; expose_region = cairo_region_copy (surface->active_update_area); - gdk_surface_process_updates_recurse (surface, expose_region); + g_signal_emit (surface, signals[RENDER], 0, expose_region, &handled); cairo_region_destroy (expose_region); } |