mirror of
https://github.com/swaywm/sway.git
synced 2026-05-03 06:46:26 -04:00
Handle empty tabbed/stacked containers when looking for popups
This commit is contained in:
parent
e84166a734
commit
476dcc5bd9
1 changed files with 6 additions and 4 deletions
|
|
@ -681,10 +681,12 @@ static struct sway_container *popup_at_container(struct sway_container *parent,
|
||||||
if (parent->layout == L_TABBED || parent->layout == L_STACKED) {
|
if (parent->layout == L_TABBED || parent->layout == L_STACKED) {
|
||||||
struct sway_seat *seat = input_manager_current_seat(input_manager);
|
struct sway_seat *seat = input_manager_current_seat(input_manager);
|
||||||
struct sway_container *child = seat_get_active_child(seat, parent);
|
struct sway_container *child = seat_get_active_child(seat, parent);
|
||||||
struct sway_container *c =
|
if (child) {
|
||||||
popup_at_container(child, lx, ly, surface, sx, sy);
|
struct sway_container *c =
|
||||||
if (c) {
|
popup_at_container(child, lx, ly, surface, sx, sy);
|
||||||
return c;
|
if (c) {
|
||||||
|
return c;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
for (int i = 0; i < parent->children->length; ++i) {
|
for (int i = 0; i < parent->children->length; ++i) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue