closeDialog: Make dialog inactive while fading out
Otherwise the user might click Kill, which would crash if the fade-out
was triggered because a Wayland window was closed.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1032
(cherry picked from commit 32fa060a62
)
This commit is contained in:
parent
f21a0ff458
commit
99d948559b
@ -192,6 +192,7 @@ var CloseDialog = GObject.registerClass({
|
|||||||
this._dialog = null;
|
this._dialog = null;
|
||||||
this._removeWindowEffect();
|
this._removeWindowEffect();
|
||||||
|
|
||||||
|
dialog.makeInactive();
|
||||||
dialog._dialog.ease({
|
dialog._dialog.ease({
|
||||||
scale_y: 0,
|
scale_y: 0,
|
||||||
mode: Clutter.AnimationMode.LINEAR,
|
mode: Clutter.AnimationMode.LINEAR,
|
||||||
|
@ -51,10 +51,16 @@ class Dialog extends St.Widget {
|
|||||||
y_align: St.Align.START });
|
y_align: St.Align.START });
|
||||||
}
|
}
|
||||||
|
|
||||||
_onDestroy() {
|
makeInactive() {
|
||||||
if (this._eventId != 0)
|
if (this._eventId != 0)
|
||||||
this._parentActor.disconnect(this._eventId);
|
this._parentActor.disconnect(this._eventId);
|
||||||
this._eventId = 0;
|
this._eventId = 0;
|
||||||
|
|
||||||
|
this.buttonLayout.get_children().forEach(c => c.set_reactive(false));
|
||||||
|
}
|
||||||
|
|
||||||
|
_onDestroy() {
|
||||||
|
this.makeInactive();
|
||||||
}
|
}
|
||||||
|
|
||||||
_modalEventHandler(actor, event) {
|
_modalEventHandler(actor, event) {
|
||||||
|
Loading…
Reference in New Issue
Block a user