Preserve surface order when moving surfaces between layers
Use a single list of layer-surfaces and only adjust the layer
instead of moving them between lists. This gives a deterministic layer ordering even when surfaces change between layers.
Commit messages have a bit more details.
I'm marking this as draft as I want to check the code paths for committed vs pending state and some other bits but wanted to get the idea out.
This helps phosh#764 (closed) as phosh doesn't need to worry about the relationship to other layers more than it does atm.
This is on top of !369 (merged).
Edited by Guido Günther