GuestProtocolAdapter
Connects the guest (composition) of a Redwood UI to the host of that UI.
Guest widgets use this to send view tree updates to the host, and to receive user events from the host.
This interface is for generated code use only.
Properties
The root of the widget tree onto which widgetSystem-produced widgets can be added. Changes to this instance are recorded as changes to Id.Root and ChildrenTag.Root.
Host versions prior to 0.10.0 contained a bug where they did not recursively remove widgets from the protocol map which leaked any child views of a removed node. We can work around this on the guest side by synthesizing removes for every node in the subtree.
Functions
There's a bug in kotlinx.serialization where decodeFromDynamic() is broken for UInt values larger than MAX_INT. For example, 4294967295 is incorrectly encoded as -1. We work around that here by special casing that type.