mirror of
https://github.com/labwc/labwc.git
synced 2025-11-05 13:29:58 -05:00
Support xwayland view resize (LAB_DECO_PART_LEFT)
This commit is contained in:
parent
9a0c2b8417
commit
e716a92c00
7 changed files with 118 additions and 49 deletions
10
deco.c
10
deco.c
|
|
@ -39,9 +39,11 @@ struct wlr_box deco_box(struct view *view, enum deco_part deco_part)
|
|||
|
||||
enum deco_part deco_at(struct view *view, double lx, double ly)
|
||||
{
|
||||
struct wlr_box box;
|
||||
box = deco_box(view, LAB_DECO_PART_TOP);
|
||||
if (wlr_box_contains_point(&box, lx, ly))
|
||||
return LAB_DECO_PART_TOP;
|
||||
enum deco_part deco_part;
|
||||
for (deco_part = 0; deco_part < LAB_DECO_NONE; ++deco_part) {
|
||||
struct wlr_box box = deco_box(view, deco_part);
|
||||
if (wlr_box_contains_point(&box, lx, ly))
|
||||
return deco_part;
|
||||
}
|
||||
return LAB_DECO_NONE;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue