# HG changeset patch
# User Olaf Wintermann <olaf.wintermann@gmail.com>
# Date 1741383218 -3600
# Node ID f74d46ffaca12c5f6c11aa415083238baeeb47ce
# Parent  beb5963c3501b93f42a0bd7d1579640b61dc78c3
fix list update when attaching a context

diff -r beb5963c3501 -r f74d46ffaca1 ui/common/context.c
--- a/ui/common/context.c	Fri Mar 07 21:46:52 2025 +0100
+++ b/ui/common/context.c	Fri Mar 07 22:33:38 2025 +0100
@@ -347,7 +347,10 @@
             *to = tmp;
 
             UiList* t2 = to->value;
-            ui_notify(t2->observers, NULL);
+            if(t->update) {
+                t->update(t, -1);
+            }
+            ui_notify(t2->observers, NULL); // TODO: why not t?
             
             break;
         }