Fix alone text in participant list (video conference).

Reload devices when entering in settings.
Remove workaround for reloading video devices while in call.
Add capture feedback in waiting room and change buttons layout.
Replace options icones.
This commit is contained in:
Julien Wadel 2022-06-29 15:26:59 +02:00
parent 237940d798
commit d015ffbf14
9 changed files with 76 additions and 51 deletions

View file

@ -39,6 +39,8 @@
ParticipantProxyModel::ParticipantProxyModel (QObject *parent) : QSortFilterProxyModel(parent) {
setSourceModel(new ParticipantListModel((ConferenceModel*)nullptr, this));
connect(this, &ParticipantProxyModel::chatRoomModelChanged, this, &ParticipantProxyModel::countChanged);
connect(this, &ParticipantProxyModel::conferenceModelChanged, this, &ParticipantProxyModel::countChanged);
}
// -----------------------------------------------------------------------------

View file

@ -73,6 +73,17 @@ void SettingsModel::settingsWindowClosing(void) {
onSettingsTabChanged(-1);
}
void SettingsModel::reloadDevices(){
CoreManager::getInstance()->getCore()->reloadSoundDevices();
emit captureDevicesChanged(getCaptureDevices());
emit playbackDevicesChanged(getPlaybackDevices());
emit playbackDeviceChanged(getPlaybackDevice());
emit captureDeviceChanged(getCaptureDevice());
emit ringerDeviceChanged(getRingerDevice());
CoreManager::getInstance()->getCore()->reloadVideoDevices();
emit videoDevicesChanged(getVideoDevices());
}
//Provides tabbar per-tab setup/teardown mechanism for specific settings views
void SettingsModel::onSettingsTabChanged(int idx) {
int prevIdx = mCurrentSettingsTab;
@ -460,7 +471,7 @@ void SettingsModel::setShowAudioCodecs (bool status) {
//Force a call on the 'detect' method of all video filters, updating new or removed devices
void SettingsModel::accessVideoSettings() {
if(!getIsInCall())// TODO : This is a workaround to a crash when reloading video devices while in call. Spotted on Macos.
//if(!getIsInCall())// TODO : This is a workaround to a crash when reloading video devices while in call. Spotted on Macos.
CoreManager::getInstance()->getCore()->reloadVideoDevices();
emit videoDevicesChanged(getVideoDevices());
}

View file

@ -238,6 +238,7 @@ public:
Q_INVOKABLE void onSettingsTabChanged(int idx);
Q_INVOKABLE void settingsWindowClosing(void);
Q_INVOKABLE void reloadDevices();
// Assistant. ----------------------------------------------------------------

View file

@ -33,7 +33,10 @@ DialogPlus {
]
buttonsAlignment: Qt.AlignCenter
onVisibleChanged: if(visible) {SettingsModel.reloadDevices()}
Component.onCompleted: {
SettingsModel.stopCaptureGraph()
SettingsModel.reloadDevices()
SettingsModel.startCaptureGraph()
if( fixedSize){
height = fitHeight

View file

@ -77,6 +77,7 @@ Rectangle {
id: loader
Layout.fillWidth: true
Layout.fillHeight: true
property int minSize: Math.min( loader.height, loader.width)
Item{
Layout.fillHeight: true
Layout.fillWidth: true
@ -84,7 +85,7 @@ Rectangle {
Flipable{
id: contentsStack
anchors.centerIn: parent
height: Math.min( loader.height, loader.width)
height: loader.minSize
width : height
property bool flipped: false
@ -110,7 +111,7 @@ Rectangle {
id: previewLoader
showCloseButton: false
enabled: mainItem.previewLoaderEnabled
height: Math.min( loader.height, loader.width)
height: loader.minSize
width : height
ActionButton{
anchors.top: parent.top
@ -153,59 +154,66 @@ Rectangle {
// -------------------------------------------------------------------------
// Action Buttons.
// -------------------------------------------------------------------------
RowLayout{
Item{
Layout.fillWidth: true
Layout.topMargin: 25
Layout.bottomMargin: 25
Layout.leftMargin: 25
Layout.rightMargin: 25
enabled: !mainItem.callModel
Item{
Layout.fillWidth: true
}
// Action buttons
// Action buttons
RowLayout{
Layout.alignment: Qt.AlignCenter
spacing: 30
RowLayout{
spacing: 10
ActionSwitch {
id: micro
visible: SettingsModel.muteMicrophoneEnabled
property bool microMuted: false
isCustom: true
backgroundRadius: 90
colorSet: microMuted ? WaitingRoomStyle.buttons.microOff : WaitingRoomStyle.buttons.microOn
onClicked: microMuted = !microMuted
}
ActionSwitch {
id: speaker
property bool speakerMuted: false
isCustom: true
backgroundRadius: 90
colorSet: speakerMuted ? WaitingRoomStyle.buttons.speakerOff : WaitingRoomStyle.buttons.speakerOn
onClicked: speakerMuted = !speakerMuted
}
ActionSwitch {
id: camera
property bool cameraEnabled: true
isCustom: true
backgroundRadius: 90
colorSet: cameraEnabled ? WaitingRoomStyle.buttons.cameraOn : WaitingRoomStyle.buttons.cameraOff
enabled: modeChoice.selectedMode != 2
onClicked: cameraEnabled = !cameraEnabled
anchors.centerIn: parent
spacing: 10
ActionSwitch {
id: micro
visible: SettingsModel.muteMicrophoneEnabled
property bool microMuted: false
isCustom: true
backgroundRadius: 90
colorSet: microMuted ? WaitingRoomStyle.buttons.microOff : WaitingRoomStyle.buttons.microOn
onClicked: microMuted = !microMuted
}
VuMeter {
enabled: !micro.microMuted
Timer {
interval: 50
repeat: true
running: parent.enabled
onTriggered: parent.value = SettingsModel.getMicVolume()
}
}
RowLayout{
ActionButton{
id: modeChoice
property int selectedMode: 0
isCustom: true
backgroundRadius: width/2
colorSet: selectedMode == 0 ? WaitingRoomStyle.buttons.gridLayout :
selectedMode == 1 ? WaitingRoomStyle.buttons.activeSpeakerLayout : WaitingRoomStyle.buttons.audioOnly
onClicked: selectedMode = (selectedMode + 1) % 3
}
ActionSwitch {
id: speaker
property bool speakerMuted: false
isCustom: true
backgroundRadius: 90
colorSet: speakerMuted ? WaitingRoomStyle.buttons.speakerOff : WaitingRoomStyle.buttons.speakerOn
onClicked: speakerMuted = !speakerMuted
}
ActionSwitch {
id: camera
property bool cameraEnabled: true
isCustom: true
backgroundRadius: 90
colorSet: cameraEnabled ? WaitingRoomStyle.buttons.cameraOn : WaitingRoomStyle.buttons.cameraOff
enabled: modeChoice.selectedMode != 2
onClicked: cameraEnabled = !cameraEnabled
}
}
RowLayout{
anchors.centerIn: parent
anchors.horizontalCenterOffset: loader.minSize/2 - modeChoice.width/2
ActionButton{
id: modeChoice
property int selectedMode: 0
isCustom: true
backgroundRadius: width/2
colorSet: selectedMode == 0 ? WaitingRoomStyle.buttons.gridLayout :
selectedMode == 1 ? WaitingRoomStyle.buttons.activeSpeakerLayout : WaitingRoomStyle.buttons.audioOnly
onClicked: selectedMode = (selectedMode + 1) % 3
}
}
Item{

View file

@ -286,7 +286,7 @@ QtObject {
}
property QtObject options: QtObject {
property int iconSize: 40
property string icon : 'options_custom'
property string icon : 'menu_vdots_custom'
property string name : 'options'
property color backgroundNormalColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_n', icon, 's_n_b_bg').color
property color backgroundHoveredColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_h', icon, 's_h_b_bg').color

View file

@ -288,7 +288,7 @@ QtObject {
}
property QtObject options: QtObject {
property int iconSize: 40
property string icon : 'options_custom'
property string icon : 'menu_vdots_custom'
property string name : 'options'
property color backgroundNormalColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_n', icon, 's_n_b_bg').color
property color backgroundHoveredColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_h', icon, 's_h_b_bg').color

View file

@ -408,7 +408,7 @@ QtObject {
}
property QtObject options: QtObject {
property int iconSize: 40
property string icon : 'options_custom'
property string icon : 'menu_vdots_custom'
property string name : 'options'
property color backgroundNormalColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_n', icon, 'me_n_b_inv_bg').color
property color backgroundHoveredColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_h', icon, 'me_h_b_inv_bg').color

View file

@ -253,7 +253,7 @@ QtObject {
}
property QtObject options: QtObject {
property int iconSize: 40
property string icon : 'options_custom'
property string icon : 'menu_vdots_custom'
property string name : 'options'
property color backgroundNormalColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_n', icon, 's_n_b_bg').color
property color backgroundHoveredColor : ColorsList.addImageColor(sectionName+'_'+name+'_bg_h', icon, 's_h_b_bg').color