fix opacity for containing mouse only

This commit is contained in:
Wayne Chen 2019-03-29 17:04:44 -07:00 committed by GitHub
parent 426ffe5a14
commit c4cccc6ef7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -56,7 +56,7 @@ Rectangle {
onLevelChanged: {
var rectOpacity = (muted && (level >= userSpeakingLevel)) ? 1.0 : 0.7;
if (pushToTalk && !pushingToTalk) {
rectOpacity = (level >= userSpeakingLevel) ? 1.0 : 0.7;
rectOpacity = (mouseArea.containsMouse) ? 1.0 : 0.7;
} else if (mouseArea.containsMouse && rectOpacity != 1.0) {
rectOpacity = 1.0;
}