mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-17 05:33:52 -04:00
wayland: terminal_from_surface(): use term_surface_kind()
This commit is contained in:
parent
7f270a9f01
commit
b725ac4c73
1 changed files with 1 additions and 4 deletions
|
|
@ -1033,11 +1033,8 @@ struct terminal *
|
||||||
wayl_terminal_from_surface(struct wayland *wayl, struct wl_surface *surface)
|
wayl_terminal_from_surface(struct wayland *wayl, struct wl_surface *surface)
|
||||||
{
|
{
|
||||||
tll_foreach(wayl->terms, it) {
|
tll_foreach(wayl->terms, it) {
|
||||||
if (it->item->window->surface == surface ||
|
if (term_surface_kind(it->item, surface) != TERM_SURF_NONE)
|
||||||
it->item->window->search_surface == surface)
|
|
||||||
{
|
|
||||||
return it->item;
|
return it->item;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
assert(false);
|
assert(false);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue