--- a/ui/gtk/image.c Sun Nov 17 15:19:32 2024 +0100 +++ b/ui/gtk/image.c Tue Nov 26 10:40:45 2024 +0100 @@ -29,6 +29,7 @@ #include "image.h" #include "container.h" +#include "menu.h" #include "../common/context.h" #include "../common/object.h" @@ -51,6 +52,7 @@ gtk_container_add(GTK_CONTAINER(eventbox), image); #else SCROLLEDWINDOW_SET_CHILD(scrolledwindow, image); + GtkWidget *eventbox = image; #endif UI_APPLY_LAYOUT1(current, args); @@ -70,6 +72,11 @@ } } + if(args.contextmenu) { + UIMENU menu = ui_contextmenu_create(args.contextmenu, obj, eventbox); + ui_widget_set_contextmenu(eventbox, menu); + } + return scrolledwindow; }