messageList: Fix invisible close buttons still working

Since commit c4f2bb5f, close buttons are hidden by making them fully
transparent rather than setting their visibility to false to keep
the overall message layout stable. As a result, the buttons now work
even when invisible, which is clearly unexpected - fix this by updating
the reactive property appropriately.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/66
This commit is contained in:
Florian Müllner 2018-02-23 10:27:07 +01:00 committed by Florian Müllner
parent c8e69a2154
commit 81dfcb85ca

View File

@ -502,6 +502,7 @@ var Message = new Lang.Class({
_sync() { _sync() {
let visible = this.actor.hover && this.canClose(); let visible = this.actor.hover && this.canClose();
this._closeButton.opacity = visible ? 255 : 0; this._closeButton.opacity = visible ? 255 : 0;
this._closeButton.reactive = visible;
}, },
_onClicked() { _onClicked() {