From 060ab606a2d9527630eb749e55a1091269c1307f Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Fri, 17 Mar 2023 11:48:44 -0400 Subject: [PATCH] gtk-demo: Reset properties when the image changes --- demos/gtk-demo/demo3widget.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/demos/gtk-demo/demo3widget.c b/demos/gtk-demo/demo3widget.c index 147ccf571d..e2ddf744e1 100644 --- a/demos/gtk-demo/demo3widget.c +++ b/demos/gtk-demo/demo3widget.c @@ -224,7 +224,14 @@ demo3_widget_set_property (GObject *object, case PROP_TEXTURE: g_clear_object (&self->texture); self->texture = g_value_dup_object (value); + self->scale = 1.f; + self->angle = 0.f; + self->filter = GSK_SCALING_FILTER_LINEAR; + update_actions (self); gtk_widget_queue_resize (GTK_WIDGET (object)); + g_object_notify (object, "scale"); + g_object_notify (object, "angle"); + g_object_notify (object, "filter"); break; case PROP_SCALE: