fix audio checkbox bindings

This commit is contained in:
Zach Pomerantz 2017-06-15 18:21:23 -04:00
parent 3093a73ce1
commit eb4255e1ac

View file

@ -60,17 +60,26 @@ Rectangle {
Audio.CheckBox {
text: qsTr("Mute microphone");
checked: Audio.muted;
onCheckedChanged: { Audio.muted = checked; }
onClicked: {
Audio.muted = checked;
checked = Qt.binding(function() { return Audio.muted; }); // restore binding
}
}
Audio.CheckBox {
text: qsTr("Enable noise reduction");
checked: Audio.noiseReduction;
onCheckedChanged: { Audio.noiseReduction = checked; }
onClicked: {
Audio.noiseReduction = checked;
checked = Qt.binding(function() { return Audio.noiseReduction; }); // restore binding
}
}
Audio.CheckBox {
text: qsTr("Show audio level meter");
checked: AvatarInputs.showAudioTools;
onCheckedChanged: { AvatarInputs.showAudioTools = checked; }
onClicked: {
AvatarInputs.showAudioTools = checked;
checked = Qt.binding(function() { return AvatarInputs.showAudioTools; }); // restore binding
}
}
}