mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
Added sound notification when recording of group call is started.
This commit is contained in:
@@ -10,5 +10,6 @@
|
||||
<file alias="group_call_connect.mp3">../../sounds/group_call_connect.mp3</file>
|
||||
<file alias="group_call_end.mp3">../../sounds/group_call_end.mp3</file>
|
||||
<file alias="group_call_allowed.mp3">../../sounds/group_call_allowed.mp3</file>
|
||||
<file alias="group_call_recording_start.mp3">../../sounds/group_call_recording_start.mp3</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
||||
Binary file not shown.
@@ -164,6 +164,8 @@ void Instance::Delegate::groupCallPlaySound(GroupCallSound sound) {
|
||||
case GroupCallSound::Ended: return "group_call_end";
|
||||
case GroupCallSound::AllowedToSpeak: return "group_call_allowed";
|
||||
case GroupCallSound::Connecting: return "group_call_connect";
|
||||
case GroupCallSound::RecordingStarted:
|
||||
return "group_call_recording_start";
|
||||
}
|
||||
Unexpected("GroupCallSound in Instance::groupCallPlaySound.");
|
||||
}());
|
||||
|
||||
@@ -2685,6 +2685,10 @@ void GroupCall::emitShareScreenError(Error error) {
|
||||
_errors.fire_copy(error);
|
||||
}
|
||||
|
||||
void GroupCall::playSoundRecordingStarted() const {
|
||||
_delegate->groupCallPlaySound(Delegate::GroupCallSound::RecordingStarted);
|
||||
}
|
||||
|
||||
void GroupCall::setupOutgoingVideo() {
|
||||
using Webrtc::VideoState;
|
||||
|
||||
|
||||
@@ -205,6 +205,7 @@ public:
|
||||
Connecting,
|
||||
AllowedToSpeak,
|
||||
Ended,
|
||||
RecordingStarted,
|
||||
};
|
||||
virtual void groupCallPlaySound(GroupCallSound sound) = 0;
|
||||
virtual auto groupCallGetVideoCapture(const QString &deviceId)
|
||||
@@ -283,6 +284,7 @@ public:
|
||||
const QString &title,
|
||||
bool video,
|
||||
bool videoPortrait);
|
||||
void playSoundRecordingStarted() const;
|
||||
[[nodiscard]] bool recordingStoppedByMe() const {
|
||||
return _recordingStoppedByMe;
|
||||
}
|
||||
|
||||
@@ -1175,6 +1175,7 @@ void Panel::subscribeToChanges(not_null<Data::GroupCall*> real) {
|
||||
const auto isVideo = real->recordVideo();
|
||||
if (recorded) {
|
||||
*startedAsVideo = isVideo;
|
||||
_call->playSoundRecordingStarted();
|
||||
}
|
||||
validateRecordingMark(recorded);
|
||||
uiShow()->showToast((recorded
|
||||
|
||||
Reference in New Issue
Block a user