Better indicate when a pushrule is disabled
This commit is contained in:
parent
db24ebc082
commit
bc0646ef90
|
@ -55,7 +55,7 @@ HFlickableColumnPopup {
|
||||||
rule.rule_id,
|
rule.rule_id,
|
||||||
isBefore && position ? position : undefined,
|
isBefore && position ? position : undefined,
|
||||||
! isBefore && position ? position : undefined,
|
! isBefore && position ? position : undefined,
|
||||||
enableCheck.checked,
|
! disableCheck.checked,
|
||||||
generalChecked ? details.matrixConditions : undefined,
|
generalChecked ? details.matrixConditions : undefined,
|
||||||
contentRadio.checked ? details.idField.text : undefined,
|
contentRadio.checked ? details.idField.text : undefined,
|
||||||
actions,
|
actions,
|
||||||
|
@ -321,9 +321,9 @@ HFlickableColumnPopup {
|
||||||
}
|
}
|
||||||
|
|
||||||
HCheckBox {
|
HCheckBox {
|
||||||
id: enableCheck
|
id: disableCheck
|
||||||
text: qsTr("Enable this rule")
|
text: qsTr("Disable this rule")
|
||||||
defaultChecked: root.rule.enabled
|
defaultChecked: ! root.rule.enabled
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -566,7 +566,7 @@ QtObject {
|
||||||
const roomColor = theme.colors.accentText
|
const roomColor = theme.colors.accentText
|
||||||
const room = ModelStore.get(userId, "rooms").find(rule.rule_id)
|
const room = ModelStore.get(userId, "rooms").find(rule.rule_id)
|
||||||
|
|
||||||
return (
|
const text =
|
||||||
rule.rule_id === ".m.rule.master" ?
|
rule.rule_id === ".m.rule.master" ?
|
||||||
qsTr("Any message") :
|
qsTr("Any message") :
|
||||||
|
|
||||||
|
@ -631,6 +631,7 @@ QtObject {
|
||||||
escapeHtml(room.display_name) :
|
escapeHtml(room.display_name) :
|
||||||
|
|
||||||
escapeHtml(rule.rule_id)
|
escapeHtml(rule.rule_id)
|
||||||
)
|
|
||||||
|
return rule.enabled ? text : qsTr("%1 (disabled rule)").arg(text)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user