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

ALLEGRO_EVENT_DISPLAY_SWITCH_IN unexpected alt-tab behavior on ubuntu 22.04 #1367

Closed
amarillion opened this issue Aug 14, 2022 · 0 comments
Closed
Milestone

Comments

@amarillion
Copy link
Contributor

I noticed that on my Linux system, the ALLEGRO_EVENT_DISPLAY_SWITCH_IN is only generated when clicking on a window, but not when alt-tabbing.

So:
Run a game window
Click outside the window
Click on the window again
-> ALLEGRO_EVENT_DISPLAY_SWITCH_IN is generated

Run a game window
Alt-tab to a different window
Alt-tab to the game window again
-> NO event generated

I would expect the behavior to be the same in both cases, as indeed it is on my Windows system.

I noticed this problem with Allegro 5.2.8.0 and Ubuntu 22.04.

@SiegeLord SiegeLord added this to the 5.2.9 milestone Nov 7, 2022
SiegeLord pushed a commit to SiegeLord/allegro5 that referenced this issue Dec 10, 2022
There were two issues.

- GNOME sends a different event type when alt-tabbing, at least on
Ubuntu 22.04. Adjusted the code to use this alternate event type.
- When GTK_TOPLEVEL flag is on, we were getting duplicate events with
Wayland. Adjusted the code to not listen to the duplicate events.

Fixes liballeg#1390, liballeg#1367
SiegeLord pushed a commit that referenced this issue Dec 31, 2022
There were two issues.

- GNOME sends a different event type when alt-tabbing, at least on
Ubuntu 22.04. Adjusted the code to use this alternate event type.
- When GTK_TOPLEVEL flag is on, we were getting duplicate events with
Wayland. Adjusted the code to not listen to the duplicate events.

Fixes #1390, #1367
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants