mirror of
https://github.com/labwc/labwc.git
synced 2025-11-04 13:30:07 -05:00
focus: add basic follow mouse support
This commit is contained in:
parent
892e93dd84
commit
00db22e44f
5 changed files with 40 additions and 0 deletions
|
|
@ -152,6 +152,15 @@ process_cursor_motion(struct server *server, uint32_t time)
|
|||
uint32_t resize_edges = get_resize_edges(
|
||||
view, server->seat.cursor->x, server->seat.cursor->y);
|
||||
switch (resize_edges) {
|
||||
case 0:
|
||||
if (rc.focus_follow_mouse){
|
||||
if (rc.raise_on_focus){
|
||||
desktop_focus_view(&server->seat, view);
|
||||
} else {
|
||||
desktop_set_focus_view_only(&server->seat, view);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case WLR_EDGE_TOP:
|
||||
cursor_name = "top_side";
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue