Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chromium/Electron apps don't receive focus under xwayland #6107

Closed
Synthetica9 opened this issue Mar 18, 2021 · 3 comments
Closed

Chromium/Electron apps don't receive focus under xwayland #6107

Synthetica9 opened this issue Mar 18, 2021 · 3 comments
Labels
bug Not working as intended window-management Configuring and arranging toplevels xwayland X11-related issues
Milestone

Comments

@Synthetica9
Copy link
Contributor

Synthetica9 commented Mar 18, 2021

Please fill out the following:

  • Sway Version:

  • Debug Log:

    • (I got the following: 00:00:00.004 [sway/main.c:355] Detected both options and positional arguments. If you are trying to use the IPC client, options are not supported. Otherwise, check the provided arguments for issues. See `man 1 sway` or `sway -h` for usage. If you are trying to generate a debug log, use `sway -d 2>sway.log`. I don't know if that's also a bug or something in NixOS. In any case, @emersion was able to reproduce on IRC.) I'm an idiot, shell redirection works differently under fish so it parsed the 2 as an argument to sway instead of 2> as "redirect stderr"
  • Configuration File:

    • Reproducible with default config
  • Description:

    • Open any window (ex. alacritty)
    • Open a chromium/vscodium/... window without ozone-platform wayland
    • Expected: the chromium window has focus. Reality: the alacritty window still has focus. This is a regression from 1.5.

cc @emersion @kennylevinsen

@Synthetica9 Synthetica9 added the bug Not working as intended label Mar 18, 2021
@emersion emersion added window-management Configuring and arranging toplevels xwayland X11-related issues labels Mar 18, 2021
@emersion emersion added this to the 1.6 milestone Mar 18, 2021
@Ghosthree3
Copy link

Ghosthree3 commented Mar 22, 2021

I'm not sure if it's the same bug but I can cause the exact same behavior opening an image with imv-x11 and sxiv.
imv-wayland works as expected, xwayland problem in general?

sway version: 1.6-rc1-03daa53a (Mar 22 2021, branch 'master')
xorg-xwayland: 21.1.0

@Synthetica9
Copy link
Contributor Author

xwayland problem in general?

It's definitely not all xwayland apps either; opening xterm for example doesn't trigger this behavior. I can also reproduce with sxiv though, good find!

emersion added a commit to emersion/wlroots that referenced this issue Mar 29, 2021
Some X11 clients (e.g. Chromium, sxiv) don't set WM_HINTS. The spec
says:

> Window managers are free to assume convenient values for all fields of the
> WM_HINTS property if a window is mapped without one.

Our wlr_xwayland_icccm_input_model function assumes missing WM_HINTS
means the window doesn't want input, but this is incorrect. Assume the
window wants input unless it explicitly opts-out by setting WM_HINTS.

Closes: swaywm/sway#6107
@emersion
Copy link
Member

Should be fixed by swaywm/wlroots#2813.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Not working as intended window-management Configuring and arranging toplevels xwayland X11-related issues
Development

No branches or pull requests

3 participants