diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-02-24 21:39:37 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-02-24 21:39:37 +0000 |
| commit | b725ac4c73526b4b54da6711e46d9ff0a7bfef3e (patch) | |
| tree | 39f4f65457c0ae83d9aab165124338b73c7dcabe | |
| parent | term: add term_surface_kind(), and track currently active surface (diff) | |
wayland: terminal_from_surface(): use term_surface_kind()
| -rw-r--r-- | wayland.c | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -1033,11 +1033,8 @@ struct terminal * wayl_terminal_from_surface(struct wayland *wayl, struct wl_surface *surface) { tll_foreach(wayl->terms, it) { - if (it->item->window->surface == surface || - it->item->window->search_surface == surface) - { + if (term_surface_kind(it->item, surface) != TERM_SURF_NONE) return it->item; - } } assert(false); |
