inclement / vivarium

A dynamic tiling Wayland compositor using wlroots
GNU General Public License v3.0
374 stars 13 forks source link

Mouse focus doesn't reset correctly on workspace change #88

Open inclement opened 3 years ago

inclement commented 3 years ago

Looks like the last focused window on the previous workspace remains focused until the cursor moves.

Not sure if this is a regression...I thought this used to work correctly but maybe I'm wrong.

It's probably a good time for a general pass through checking both keyboard and cursor focus change correctly on each transition.

flaviozavan commented 2 years ago

I couldn't' reproduce this, but I am not entirely sure how to test it. I can use the windows just fine, but maybe I am missing some specific mouse behavior. Is this still applicable?

I am working on a couple of similar issues (including #114 ), a WIP branch is here, and since I plan on using the code for a few weeks before opening a PR, it seems like a good opportunity to tackle this as well.

inclement commented 2 years ago

Hmm, I don't remember fixing this (and I don't see a commit for it) but I don't think I've noticed it any time recently whereas I originally reported the bug because I was hitting it regularly. It might have been something a bit more subtle than always getting mouse focus wrong.

I'd be happy to close this issue until if and when anyone rediscovers it and can make a better report.

flaviozavan commented 2 years ago

While debugging the 0.15 pointer focus issues, I realized we aren't sending enters pointer enters when switching workspaces. I updated that WIP branch. However, while the focus seems to be sent along correctly, applications don't necessarily handle it well. For example this page. If you open it, then switch to another workspace, move the pointer a bit, then switch back, the ball will only move when the cursor moves, despite the browser having pointer focus. It's a step in the right direction, though.

Edit: the ball fails to move on Firefox, but moves on Chrome. I guess this means the behavior I implemented is probably correct