mirror of
https://github.com/labwc/labwc.git
synced 2025-11-04 13:30:07 -05:00
SnapToRegion: Add SnapToRegion action
This commit is contained in:
parent
9d3e309a22
commit
96a591297d
3 changed files with 43 additions and 0 deletions
|
|
@ -25,6 +25,20 @@ regions_init(struct server *server, struct seat *seat)
|
|||
/* To be filled later */
|
||||
}
|
||||
|
||||
struct region *
|
||||
regions_from_name(const char *region_name, struct output *output)
|
||||
{
|
||||
assert(region_name);
|
||||
assert(output);
|
||||
struct region *region;
|
||||
wl_list_for_each(region, &output->regions, link) {
|
||||
if (!strcmp(region->name, region_name)) {
|
||||
return region;
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void
|
||||
regions_update(struct output *output)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue