overview: Port to Meta.Display.is_grabbed()

The get_grab_op() method is disappearing, replaced by this
new method.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2526>
This commit is contained in:
Carlos Garnacho 2022-09-29 14:23:31 +02:00 committed by Marge Bot
parent ac42eb62f8
commit 238a17c6b5

View File

@ -458,8 +458,7 @@ var Overview = class extends Signals.EventEmitter {
if (this._shown) {
let shouldBeModal = !this._inXdndDrag;
if (shouldBeModal && !this._modal) {
if (global.display.get_grab_op() !== Meta.GrabOp.NONE &&
global.display.get_grab_op() !== Meta.GrabOp.WAYLAND_POPUP) {
if (global.display.is_grabbed()) {
this.hide();
return false;
}