Skip to content

Commit

Permalink
[client] x11/i3: fix fullscreen at launch via parameter/config
Browse files Browse the repository at this point in the history
  • Loading branch information
gnif committed Mar 14, 2024
1 parent 20972cf commit 7f515c5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion client/displayservers/X11/x11.c
Original file line number Diff line number Diff line change
Expand Up @@ -699,7 +699,7 @@ static bool x11Init(const LG_DSInitParams params)
XMoveWindow(x11.display, x11.window, params.x, params.y);

if (params.fullscreen)
x11SetFullscreen(true);
x11.doFullscreenOnExpose = true;

XSetLocaleModifiers(""); // Load XMODIFIERS
x11.xim = XOpenIM(x11.display, 0, 0, 0);
Expand Down Expand Up @@ -946,6 +946,11 @@ static int x11EventThread(void * unused)
{
atomic_store(&x11.lastWMEvent, microtime());
x11.invalidateAll = true;
if (x11.doFullscreenOnExpose)
{
x11SetFullscreen(true);
x11.doFullscreenOnExpose = false;
}
break;
}

Expand Down
1 change: 1 addition & 0 deletions client/displayservers/X11/x11.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ struct X11DSState

_Atomic(uint64_t) lastWMEvent;
bool invalidateAll;
bool doFullscreenOnExpose;

int xpresentOp;
bool jitRender;
Expand Down

0 comments on commit 7f515c5

Please sign in to comment.