diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/wlt_toolkit.c | 10 | ||||
-rw-r--r-- | src/wlt_toolkit.h | 2 |
2 files changed, 12 insertions, 0 deletions
diff --git a/src/wlt_toolkit.c b/src/wlt_toolkit.c index 548cb1e..18a0233 100644 --- a/src/wlt_toolkit.c +++ b/src/wlt_toolkit.c @@ -1813,6 +1813,11 @@ void wlt_window_toggle_maximize(struct wlt_window *wnd) wnd->maximized = !wnd->maximized; } +bool wlt_window_is_maximized(struct wlt_window *wnd) +{ + return wnd && wnd->maximized; +} + void wlt_window_toggle_fullscreen(struct wlt_window *wnd) { if (!wnd) @@ -1840,6 +1845,11 @@ void wlt_window_toggle_fullscreen(struct wlt_window *wnd) wnd->fullscreen = !wnd->fullscreen; } +bool wlt_window_is_fullscreen(struct wlt_window *wnd) +{ + return wnd && wnd->fullscreen; +} + struct ev_eloop *wlt_window_get_eloop(struct wlt_window *wnd) { if (!wnd) diff --git a/src/wlt_toolkit.h b/src/wlt_toolkit.h index 20fac59..44ce0ec 100644 --- a/src/wlt_toolkit.h +++ b/src/wlt_toolkit.h @@ -164,7 +164,9 @@ void wlt_window_set_close_cb(struct wlt_window *wnd, wlt_window_close_cb cb); void wlt_window_close(struct wlt_window *wnd); void wlt_window_toggle_maximize(struct wlt_window *wnd); +bool wlt_window_is_maximized(struct wlt_window *wnd); void wlt_window_toggle_fullscreen(struct wlt_window *wnd); +bool wlt_window_is_fullscreen(struct wlt_window *wnd); struct ev_eloop *wlt_window_get_eloop(struct wlt_window *wnd); struct wlt_display *wlt_window_get_display(struct wlt_window *wnd); |