Mir-kiosk - managing multiple windows and focus priority


We are using mir-kiosk for display, and have an X application which connects via Xwayland. That works fine. Let’s call that the primary app. We have another application that we also want to display via mir-kiosk, but only when the primary application is not running. This second application is using another instance of Xwayland to connect to mir-kiosk, but we could change it to be native Wayland if that helps with out problem.

Currently it seems the behaviour is last app to start gets full screen focus. However, we want to ensure that the secondary app never steals focus from the primary app. Can we in some way tell mir-kiosk to ensure focus on the primary app, or to always send the secondary app to the back ?

Would making apps Wayland native help ? Would ubuntu-tile instead of mir-kiosk help with this issue ?

@alan_g Sorry to @ you again - but this is definitely your area of expertise :slight_smile: - hope you don’t mind.

Cheers, Just

The “kiosk” shell targets “a single fullscreen application”, so there’s nothing that does this by default.

You could enable the “Foreign Toplevel” and “Layer Shell” Wayland extensions in the mir-kiosk configuration, and then the secondary application could (if using Wayland) have access to these and behave as you describe.