overlay: refactor

- Use a single `lab_scene_rect` for both overlay background and outlines,
  like I described in the TODO comment in ffd4005.
- Simplify the resource management by destroying the overlay tree when
  it's hidden. I think its overhead is pretty minimal.
- Share a single `lab_scene_rect` for both region/edge overlays.
This commit is contained in:
tokyo4j 2025-08-31 04:41:08 +09:00 committed by Johan Malm
parent 78d47c5c37
commit 66e26cd28a
8 changed files with 51 additions and 154 deletions

View file

@ -171,7 +171,7 @@ handle_output_destroy(struct wl_listener *listener, void *data)
regions_evacuate_output(output);
regions_destroy(seat, &output->regions);
if (seat->overlay.active.output == output) {
overlay_hide(seat);
overlay_finish(seat);
}
wl_list_remove(&output->link);
wl_list_remove(&output->frame.link);