fix unmute when ignoring in PAL (you can't)

This commit is contained in:
David Kelly 2017-03-02 08:36:58 -07:00
parent 48ad7fcaae
commit 79e440be81

View file

@ -300,6 +300,8 @@ Rectangle {
anchors.verticalCenter: parent.verticalCenter
anchors.horizontalCenter: parent.horizontalCenter
onClicked: {
// cannot change mute status when ignoring
if (!model["ignore"]) {
var newValue = !model["personalMute"];
userModel.setProperty(model.userIndex, "personalMute", newValue)
userModelData[model.userIndex]["personalMute"] = newValue // Defensive programming
@ -307,6 +309,7 @@ Rectangle {
UserActivityLogger["palAction"](newValue ? "personalMute" : "un-personalMute", model.sessionId)
}
}
}
// This CheckBox belongs in the columns that contain the stateful action buttons ("Mute" & "Ignore" for now)
// KNOWN BUG with the Checkboxes: When clicking in the center of the sorting header, the checkbox
@ -336,6 +339,7 @@ Rectangle {
} else {
delete ignored[model.sessionId]
}
avgAudioVolume.glyph = avgAudioVolume.getGlyph()
}
// http://doc.qt.io/qt-5/qtqml-syntax-propertybinding.html#creating-property-bindings-from-javascript
// I'm using an explicit binding here because clicking a checkbox breaks the implicit binding as set by