Mir

Code review comment for lp:~mterry/mir/session-for-surface

Revision history for this message
Michael Terry (mterry) wrote :

Here's my use case:
I want to change u-s-c to be able to place a specified user session under the greeter session, so the user session can bleed through (e.g. imagine the pin unlock screen that shows a blurred user session underneath).

Here's my current thinking on how to do so:
A) Change u-s-c to override the_surface_builder(), note which surfaces are associated with the greeter, and create those surfaces with a different depth than other surfaces (so they float above in a different layer than all other sessions).
B) Then, have lightdm tell u-s-c which session is the greeter (by naming it something like "Greeter 1") and when to raise the appropriate user session inside of its layer.

Here's the missing piece:
u-s-c can't seem to tell me that a given surface belongs to a session called "Greeter 1", so I can't create it with the right depthId. Hence this proposal.

I'm open to other ways of achieving the use case. Including some special case API like "Keep this session above these others" or "Put this session below this other one". But this MP seemed more generally useful.

And yeah, I didn't need the session pointer to be stored long term. Just needed to inspect it momentarily. So for my specific use case, eventual segfaults from storing it is not as much a problem.

« Back to merge proposal