Implement resizing floating clients with Mod1 + right mouse button

This commit is contained in:
Michael Stapelberg
2009-08-22 07:49:28 +02:00
parent 32532792cd
commit c7ba95e79d
4 changed files with 50 additions and 2 deletions

View File

@ -380,7 +380,14 @@ int handle_button_press(void *ignored, xcb_connection_t *conn, xcb_button_press_
return 1;
}
if (client_is_floating(client)) {
floating_drag_window(conn, client, event);
LOG("button %d pressed\n", event->detail);
if (event->detail == 1) {
LOG("left mouse button, dragging\n");
floating_drag_window(conn, client, event);
} else if (event->detail == 3) {
LOG("right mouse button\n");
floating_resize_window(conn, client, event);
}
return 1;
}
}