ctrlAltTab: Fix more fallout from ES6 classes
Since ShellGenericContainer was removed, switcher popups and lists are StWidget subclasses rather than plain JS classes. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/411
This commit is contained in:
parent
8490173879
commit
bbd68626cc
@ -1,6 +1,6 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
|
|
||||||
const { Clutter, Meta, Shell, St } = imports.gi;
|
const { Clutter, GObject, Meta, Shell, St } = imports.gi;
|
||||||
|
|
||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
const SwitcherPopup = imports.ui.switcherPopup;
|
const SwitcherPopup = imports.ui.switcherPopup;
|
||||||
@ -129,10 +129,10 @@ var CtrlAltTabManager = class CtrlAltTabManager {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
var CtrlAltTabPopup =
|
var CtrlAltTabPopup = GObject.registerClass(
|
||||||
class CtrlAltTabPopup extends SwitcherPopup.SwitcherPopup {
|
class CtrlAltTabPopup extends SwitcherPopup.SwitcherPopup {
|
||||||
constructor(items) {
|
_init(items) {
|
||||||
super(items);
|
super._init(items);
|
||||||
|
|
||||||
this._switcherList = new CtrlAltTabSwitcher(this._items);
|
this._switcherList = new CtrlAltTabSwitcher(this._items);
|
||||||
}
|
}
|
||||||
@ -156,12 +156,12 @@ class CtrlAltTabPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
super._finish(time);
|
super._finish(time);
|
||||||
Main.ctrlAltTabManager.focusGroup(this._items[this._selectedIndex], time);
|
Main.ctrlAltTabManager.focusGroup(this._items[this._selectedIndex], time);
|
||||||
}
|
}
|
||||||
};
|
});
|
||||||
|
|
||||||
var CtrlAltTabSwitcher =
|
var CtrlAltTabSwitcher = GObject.registerClass(
|
||||||
class CtrlAltTabSwitcher extends SwitcherPopup.SwitcherList {
|
class CtrlAltTabSwitcher extends SwitcherPopup.SwitcherList {
|
||||||
constructor(items) {
|
_init(items) {
|
||||||
super(true);
|
super._init(true);
|
||||||
|
|
||||||
for (let i = 0; i < items.length; i++)
|
for (let i = 0; i < items.length; i++)
|
||||||
this._addIcon(items[i]);
|
this._addIcon(items[i]);
|
||||||
@ -183,4 +183,4 @@ class CtrlAltTabSwitcher extends SwitcherPopup.SwitcherList {
|
|||||||
|
|
||||||
this.addItem(box, text);
|
this.addItem(box, text);
|
||||||
}
|
}
|
||||||
};
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user