🔧 Use global.compositor.enable_unredirect on GNOME 48
This commit is contained in:
+15
-4
@@ -115,8 +115,14 @@ export var Shader = GObject.registerClass({
|
|||||||
this._timeline.set_duration(duration);
|
this._timeline.set_duration(duration);
|
||||||
this._timeline.start();
|
this._timeline.start();
|
||||||
|
|
||||||
// Make sure that no fullscreen window is drawn over our animations.
|
// Make sure that no fullscreen window is drawn over our animations. Since GNOME 48 this is a
|
||||||
Meta.disable_unredirect_for_display(global.display);
|
// "global" method.
|
||||||
|
if (Meta.disable_unredirect_for_display) {
|
||||||
|
Meta.disable_unredirect_for_display(global.display);
|
||||||
|
} else {
|
||||||
|
global.compositor.disable_unredirect();
|
||||||
|
}
|
||||||
|
|
||||||
global.begin_work();
|
global.begin_work();
|
||||||
|
|
||||||
// Reset progress value.
|
// Reset progress value.
|
||||||
@@ -156,8 +162,13 @@ export var Shader = GObject.registerClass({
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Restore unredirecting behavior for fullscreen windows.
|
// Restore unredirecting behavior for fullscreen windows. Since GNOME 48 this is a
|
||||||
Meta.enable_unredirect_for_display(global.display);
|
// "global" method.
|
||||||
|
if (Meta.disable_unredirect_for_display) {
|
||||||
|
Meta.enable_unredirect_for_display(global.display);
|
||||||
|
} else {
|
||||||
|
global.compositor.enable_unredirect();
|
||||||
|
}
|
||||||
global.end_work();
|
global.end_work();
|
||||||
|
|
||||||
this.emit('end-animation');
|
this.emit('end-animation');
|
||||||
|
|||||||
Reference in New Issue
Block a user