This repository has been archived by the owner on Sep 11, 2024. It is now read-only.
Make video rooms compatible with matrix RTC #11829
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
After a lot of trying I actually found a stepping store solution.
It is possible to get it working with very minimal changes when beeing careful.
Its all slighly more fragile than I would want It to be.
Especially there need to be desitions made on when we add/remove the widget.
For video rooms the widget now always lives and never gets destroyed.
For normal rooms the widget is the indicator that the usere created a call. So we create the widget on call button press but only connect the widget once the lobby ends.
If the call ends we destroy the widget because it is our indicator that the user created a call so the ui would show a call after the hangup as long as the widget lives.
Sadly we need to emit here from the outside. It would be nicer if createVirtualWidget would call the WidgetStore update automatically. But then
WidgetStore.instance.emit(UPDATE_EVENT, null);
also would be called during theCall.get()
fn. But this is causing iussues in the CallStore.If Call.get() calls
WidgetStore.instance.emit(UPDATE_EVENT, null);
we create two widgets since the second call atHERE
also would call the updateRoom again and we end up with two widgets.Checklist
This change is marked as an internal change (Task), so will not be included in the changelog.