File tree Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -462,23 +462,18 @@ static void _window_moved_to_rect(GdkWindow *window,
462462static void _window_position (const int offset )
463463{
464464 dt_bauhaus_popup_t * pop = & darktable .bauhaus -> popup ;
465-
466- if (pop -> composited && gtk_widget_get_visible (pop -> window ))
467- {
468- pop -> offcut += offset ;
469- return ;
470- }
471-
472465 int height = pop -> position .height ;
473- pop -> offset += offset ;
474466
475- pop -> composited = FALSE;
476467 // On Xwayland gdk_screen_is_composited is TRUE but popups are opaque
477468 // So we need to explicitly test for pure wayland
478469#ifdef GDK_WINDOWING_WAYLAND
479470 if (GDK_IS_WAYLAND_DISPLAY (gtk_widget_get_display (pop -> window )))
480471 {
481- pop -> composited = TRUE;
472+ if (gtk_widget_get_visible (pop -> window ))
473+ {
474+ pop -> offcut += offset ;
475+ return ;
476+ }
482477 gtk_widget_set_app_paintable (pop -> window , TRUE);
483478 GdkScreen * screen = gtk_widget_get_screen (pop -> window );
484479 GdkVisual * visual = gdk_screen_get_rgba_visual (screen );
@@ -488,6 +483,8 @@ static void _window_position(const int offset)
488483 }
489484#endif
490485
486+ pop -> offset += offset ;
487+
491488 if (pop -> offcut > 0 )
492489 pop -> offcut = MAX (0 , pop -> offcut + offset );
493490
Original file line number Diff line number Diff line change @@ -185,7 +185,6 @@ typedef struct dt_bauhaus_popup_t
185185 GdkRectangle position ;
186186 int offset ;
187187 int offcut ;
188- gboolean composited ;
189188} dt_bauhaus_popup_t ;
190189
191190typedef struct dt_bauhaus_t
You can’t perform that action at this time.
0 commit comments