Open focustense opened 2 weeks ago
I think I'm going to punt this to a Beta 3. Most users will not need overlays, and Beta 2 has been largely focused on getting it into a widely usable and releasable state through better error handling, performance improvements, critical bug fixes, tooling and so on. This task still needs design work and would unnecessarily hold up the R2 release.
Overlays are a feature of the Core library that is not supported in the Framework right now. They were originally intended mostly as an internal utility for custom widgets, but have certain uses in user UI, like menu stacks as an alternative to the fussy
ChildMenu
in vanilla.I'm not sure what the API design might look like at this point.
IOverlay
is going to be more troublesome than the simplifiedIDrawable
in #16. It's not a good candidate for directly passing over the API boundary for the same reasons asIView
, but overlays exist as a stack with random access and it's not so simple to manipulate without access to the underlying types.If all we need is
Push
andPop
, those can probably be implemented as API wrappers viaPushAsset
/PushMarkup
and aPop
that simply returns a boolean or maybe an ID or something that can be proxied easily, just not the wholeIOverlay
.Remove
is much trickier. Maybe it can be handled by returning anIDisposable
fromPush
.OnClose
is similarly finicky. I'm not sure how or if events work over Pintail. Maybe they are actually fine. Otherwise, maybePush
can accept aclose
callback.These are just random thoughts and ideas for now. I'll update this when I have a clearer idea of how to make this accessible without making a big mess.