render: never render CSD and/or search box "immediately"

Handle the CSDs and the search box the same way we handle the main
grid; when we need to redraw them, call
render_refresh_{csd,search}(). This sets a flag that is checked after
each FDM iteration. All actual rendering is done here.

This also ties the commits of the Wayland sub-surfaces to the commit
of the main surface.
This commit is contained in:
Daniel Eklöf 2020-03-06 19:16:54 +01:00
parent e5540a0d2e
commit c5a1af4e53
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
6 changed files with 118 additions and 81 deletions

11
input.c
View file

@ -711,13 +711,9 @@ wl_pointer_enter(void *data, struct wl_pointer *wl_pointer,
case TERM_SURF_BUTTON_MINIMIZE:
case TERM_SURF_BUTTON_MAXIMIZE:
case TERM_SURF_BUTTON_CLOSE:
quirk_weston_csd_on(term);
render_csd(term);
quirk_weston_csd_off(term);
render_refresh(term);
term->xcursor = "left_ptr";
render_xcursor_set(term);
render_refresh_csd(term);
break;
case TERM_SURF_NONE:
@ -771,10 +767,7 @@ wl_pointer_leave(void *data, struct wl_pointer *wl_pointer,
if (old_moused->is_shutting_down)
break;
quirk_weston_csd_on(old_moused);
render_csd(old_moused);
quirk_weston_csd_off(old_moused);
render_refresh(old_moused);
render_refresh_csd(old_moused);
break;
case TERM_SURF_NONE: