[gtk] fpsoverlay: Fix fps overlay position



commit 58e6c277b001d02b55de7db757bba7dabc4420c3
Author: Timm Bäder <mail baedert org>
Date:   Wed Jul 10 08:26:00 2019 +0200

    fpsoverlay: Fix fps overlay position

 gtk/inspector/fpsoverlay.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/gtk/inspector/fpsoverlay.c b/gtk/inspector/fpsoverlay.c
index dadf1ffe14..a659c1dcdd 100644
--- a/gtk/inspector/fpsoverlay.c
+++ b/gtk/inspector/fpsoverlay.c
@@ -159,7 +159,7 @@ gtk_fps_overlay_snapshot (GtkInspectorOverlay *overlay,
   double fps;
   char *fps_string;
   graphene_rect_t bounds;
-  gboolean has_bounds = FALSE;
+  gboolean has_bounds;
   int width, height;
   double overlay_opacity;
 
@@ -207,6 +207,8 @@ gtk_fps_overlay_snapshot (GtkInspectorOverlay *overlay,
       if (!child ||
           !gtk_widget_compute_bounds (child, widget, &bounds))
         has_bounds = gtk_widget_compute_bounds (widget, widget, &bounds);
+      else
+        has_bounds = gtk_widget_compute_bounds (child, widget, &bounds);
     }
   else
     {


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