gtk-demo: Update fps with higher priority

We want to make sure to always update it, so make sure it has a higher
priority than redraws.
This commit is contained in:
Benjamin Otte
2023-05-09 14:36:45 +02:00
parent 02e2a6f311
commit 30acf00bf8

View File

@@ -370,7 +370,7 @@ do_iconscroll (GtkWidget *do_widget)
set_widget_type (0);
label = GTK_WIDGET (gtk_builder_get_object (builder, "fps_label"));
id = g_timeout_add (500, update_fps, label);
id = g_timeout_add_full (G_PRIORITY_HIGH, 500, update_fps, label, NULL);
g_object_set_data_full (G_OBJECT (label), "timeout",
GUINT_TO_POINTER (id), remove_timeout);