When automating multiple applications or a single application with multiple windows it can be useful (or required) to bring one window to the foreground, or to make the non active application active.
The problem with this is that modern operating systems and window managers actively try to prevent that an application makes itself active. And this is something that Squish cannot change.
However, sometimes the following workarounds might work.
This relies on the side effect that closing a QMessageBox will activate the respective application:
On Linux you may have to configure the following:
- System Settings
- "Window Behavior (possibly under "Look & Feel")
- Window Behavior
- Tab Focus
(German: "Fensterverhalten", "Fensterverhalten", "Aktivierung", "Vorbeugung gegen unerwünschte Aktivierung".)
Look for the setting "Focus stealing prevention level" and set it to None.
Changing this setting may require a reboot or relogin to take effect.