🐛 Trying to fix something
This commit is contained in:
@@ -94,8 +94,9 @@ class CallNotifier extends _$CallNotifier {
|
|||||||
// Subscribe to websocket updates
|
// Subscribe to websocket updates
|
||||||
return const CallState(
|
return const CallState(
|
||||||
isConnected: false,
|
isConnected: false,
|
||||||
isMicrophoneEnabled: true,
|
isMicrophoneEnabled:
|
||||||
isCameraEnabled: false,
|
true, // Audio enabled by default (matches WebRTC init)
|
||||||
|
isCameraEnabled: true, // Video enabled by default (matches WebRTC init)
|
||||||
isScreenSharing: false,
|
isScreenSharing: false,
|
||||||
isSpeakerphone: true,
|
isSpeakerphone: true,
|
||||||
);
|
);
|
||||||
|
@@ -167,6 +167,13 @@ class WebRTCManager {
|
|||||||
if (participant != null) {
|
if (participant != null) {
|
||||||
participant.remoteStream = event.streams[0];
|
participant.remoteStream = event.streams[0];
|
||||||
participant.isConnected = true;
|
participant.isConnected = true;
|
||||||
|
|
||||||
|
// Detect video tracks and update video enabled state
|
||||||
|
final videoTracks = event.streams[0].getVideoTracks();
|
||||||
|
if (videoTracks.isNotEmpty) {
|
||||||
|
participant.isVideoEnabled = true;
|
||||||
|
}
|
||||||
|
|
||||||
_participantController.add(participant);
|
_participantController.add(participant);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user