Open romangg opened 4 years ago
One issue is that we would need to make Wayland::Resource friend of every class being created because the ctors are private.
I think we should wait with solving this issue until we have a plan for further layering of the server library. Then the ctors would be likely all public (implementation classes in a detail
namespace).
It should be possible to add a template factory method to Wayland::Resource such that the version is queried automatically from the parent resource/bind.
That could also nicely catch errors on resource creation and in that case just hand back a nullptr.