cleanup: Stop using Mainloop module
It is deprecated in favor of the regular GLib functions. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/718
This commit is contained in:
@ -3,7 +3,6 @@
|
||||
const UI = imports.testcommon.ui;
|
||||
|
||||
const { Clutter, GLib, St } = imports.gi;
|
||||
const Mainloop = imports.mainloop;
|
||||
|
||||
const DELAY = 2000;
|
||||
|
||||
@ -59,14 +58,14 @@ function test() {
|
||||
|
||||
resize_animated(label1);
|
||||
resize_animated(label2);
|
||||
Mainloop.timeout_add(DELAY, () => {
|
||||
GLib.timeout_add(GLib.PRIORITY_DEFAULT, DELAY, () => {
|
||||
log(label1 + label1.get_size());
|
||||
resize_animated(label1);
|
||||
resize_animated(label2);
|
||||
return true;
|
||||
});
|
||||
|
||||
Mainloop.timeout_add(2 * DELAY, () => {
|
||||
GLib.timeout_add(GLib.PRIORITY_DEFAULT, 2 * DELAY, () => {
|
||||
iter += 1;
|
||||
iter %= shadowStyles.length;
|
||||
label1.set_style(get_css_style(shadowStyles[iter]));
|
||||
|
Reference in New Issue
Block a user