Mir

Code review comment for lp:~mir-team/mir/allow-lock-surf-orientation

Revision history for this message
Alberto Aguirre (albaguirre) wrote :

> Also - what is the expectation if you call
> mir_surface_set_supported_orientations() and don't include the *current*
> orientation in the set of supported orientations?
>
> It's technically possible to change MirOrientation to a bitfield without
> changing ABI by the magic of symbol versioning - since
> mir_surface_get_orientation is the only client-visible user of MirOrientation
> you'd just need to provide a translation shim for that one function.

One also needs to translate the orientation values for the event handler during orientation events.

>
> I guess I'm suggesting that MirPermittedOrientations shouldn't exist :)

Right the options were break the ABI and change the existing MirOrientation enum, introduce a new enum and avoid symbol magic or use symbol magic and maintain backwards compatibility.

I've done the latter locally (symbol magic) but the results in oddness in testing and because of the event handler, MirSurface then needs to know whether to translate the values or not depending on the client symbol version that setup the handler.

« Back to merge proposal