diff --git a/externals/ggee/gui/image.c b/externals/ggee/gui/image.c
index ba0d7b2c8639a189adb0ad2bb7ab39609fd3bcad..acccd2ae49069e822a3b7c7f59dc96e469a12420 100644
--- a/externals/ggee/gui/image.c
+++ b/externals/ggee/gui/image.c
@@ -181,7 +181,7 @@ static void image_select(t_gobj *z, t_glist *glist, int state)
 	t_image *x = (t_image *)z;
 	x->x_selected = state;
 	if (state) {
-		if (glist_istoplevel(glist)) {
+		if (x->x_glist == glist_getcanvas(glist)) {
 			if (!x->x_gop_spill && (x->x_img_width + x->x_img_height) >= 2)
 				sys_vgui(".x%x.c create rectangle \
 					%d %d %d %d -tags %xSEL -outline $select_color\n",