wip: Add state saving plumbing
This branch is an exploration of apis to do save and restore application state.
Some inspiration from: https://developer.apple.com/documentation/uikit/view_controllers/preserving_your_app_s_ui_across_launches
Problems with the prototype:
-
We need save-id's on all parents of a widget, since we're recursing the tree. Some of those parents may be entirely internal and hidden from app developers, so it is impractical to expect them to set those ids.
-
A bit awkward to replace ::activate with ::create-window like this
-
In the exampleapp testcase, using the x to close the window doesn't save state, since we don't call g_application_quit() in that case
-
We need compositor support to save window positions on Wayland
Edited by Emmanuele Bassi