clients: Add support for the minimize button
This commit is contained in:
+13
-2
@@ -2354,8 +2354,10 @@ frame_handle_status(struct window_frame *frame, struct input *input,
|
|||||||
if (status & FRAME_STATUS_REPAINT)
|
if (status & FRAME_STATUS_REPAINT)
|
||||||
widget_schedule_redraw(frame->widget);
|
widget_schedule_redraw(frame->widget);
|
||||||
|
|
||||||
if (status & FRAME_STATUS_MINIMIZE)
|
if (status & FRAME_STATUS_MINIMIZE) {
|
||||||
fprintf(stderr,"Minimize stub\n");
|
window_set_minimized(window);
|
||||||
|
frame_status_clear(frame->frame, FRAME_STATUS_MINIMIZE);
|
||||||
|
}
|
||||||
|
|
||||||
if (status & FRAME_STATUS_MENU) {
|
if (status & FRAME_STATUS_MENU) {
|
||||||
window_show_frame_menu(window, input, time);
|
window_show_frame_menu(window, input, time);
|
||||||
@@ -4204,6 +4206,15 @@ window_set_maximized(struct window *window, int maximized)
|
|||||||
window_delay_redraw(window);
|
window_delay_redraw(window);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
window_set_minimized(struct window *window)
|
||||||
|
{
|
||||||
|
if (!window->xdg_surface)
|
||||||
|
return;
|
||||||
|
|
||||||
|
xdg_surface_set_minimized(window->xdg_surface);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
window_set_user_data(struct window *window, void *data)
|
window_set_user_data(struct window *window, void *data)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -376,6 +376,9 @@ window_is_maximized(struct window *window);
|
|||||||
void
|
void
|
||||||
window_set_maximized(struct window *window, int maximized);
|
window_set_maximized(struct window *window, int maximized);
|
||||||
|
|
||||||
|
void
|
||||||
|
window_set_minimized(struct window *window);
|
||||||
|
|
||||||
void
|
void
|
||||||
window_set_user_data(struct window *window, void *data);
|
window_set_user_data(struct window *window, void *data);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user