contain client fullscreen inside kick; decouple from the host window
a client's fullscreen request used to be mirrored onto the host window via libdecor, but labwc 0.9.8 expires its 100 ms configure deadline under load and then applies "move but keep old size" permanently -- the enlarged image anchored at the old origin with black margins. the mirror is gone: a client's fullscreen now fills kick's output only, leaving the host window alone. fullscreening the host remains an explicit act (prefix+F11 or the compositor), and the host-to-clients propagation is unchanged.
This commit is contained in:
parent
79ae788bfc
commit
aafd2de5b7
3 changed files with 32 additions and 24 deletions
15
kick.c
15
kick.c
|
|
@ -2642,12 +2642,13 @@ static void handle_request_fullscreen(struct wl_listener *listener, void *data)
|
|||
if (!toplevel->base->initialized) return;
|
||||
/* wlroots 0.19 emits request_fullscreen with NULL data; the direction
|
||||
lives in toplevel->requested.fullscreen. Honor the client's request
|
||||
and mirror it onto the host window: a fullscreen client fills the
|
||||
host window, and an un-fullscreen client puts it back. */
|
||||
within kick only: the window fills our output while the host window
|
||||
itself is left alone. Fullscreening the host window is a separate,
|
||||
explicit act (prefix+F11 or the compositor), which propagates back
|
||||
down through clients_set_fullscreen(). */
|
||||
bool fs = toplevel->requested.fullscreen;
|
||||
wlr_xdg_toplevel_set_fullscreen(toplevel, fs);
|
||||
kick_log(KICK_LOG_INFO, "client fullscreen=%d\n", fs);
|
||||
host_queue_fullscreen(fs);
|
||||
}
|
||||
|
||||
/* Propagate the host window's fullscreen state onto every client -- each
|
||||
|
|
@ -3644,11 +3645,10 @@ static void handle_xs_request_fullscreen(struct wl_listener *listener,
|
|||
struct kick_app *app = wl_container_of(listener, app, request_fullscreen);
|
||||
struct wlr_xwayland_surface *xs = app->xsurface;
|
||||
if (!xs) return;
|
||||
/* Mirror onto the host window like the xdg path. */
|
||||
/* Same containment as the xdg path: fullscreen stays inside kick. */
|
||||
bool fs = xs->fullscreen;
|
||||
wlr_xwayland_surface_set_fullscreen(xs, fs);
|
||||
kick_log(KICK_LOG_INFO, "client fullscreen=%d\n", fs);
|
||||
host_queue_fullscreen(fs);
|
||||
}
|
||||
|
||||
static void handle_xs_request_configure(struct wl_listener *listener,
|
||||
|
|
@ -5766,6 +5766,7 @@ static void host_teardown_window(void) {
|
|||
static void host_frame_configure(struct libdecor_frame *frame,
|
||||
struct libdecor_configuration *config,
|
||||
void *data)
|
||||
{
|
||||
(void)data;
|
||||
int width = 0, height = 0;
|
||||
bool size_ok =
|
||||
|
|
@ -6361,8 +6362,8 @@ static bool process_key_event(uint32_t time, uint32_t key, uint32_t state,
|
|||
/* Function keys are not grabbed (prefix+F11 above is the one exception):
|
||||
they pass through to the focused client, which may have its own
|
||||
bindings (e.g. a browser's F11 fullscreen request, which
|
||||
handle_request_fullscreen mirrors onto the host window). Frame dumps
|
||||
are available via SIGUSR1 instead. */
|
||||
handle_request_fullscreen contains inside kick). Frame dumps are
|
||||
available via SIGUSR1 instead. */
|
||||
/* Alt+Up / Alt+Down cycle tabs. Grabbed so the focused client never
|
||||
sees them. The host sends a single physical press, so repeats are
|
||||
synthesized by kbd_repeat_start(); subsequent host presses of an
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue