dash: Move item declaration on top

Otherwise it is not clear what is the item variable that we are
passing to _itemMenuStateChanged().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2988>
This commit is contained in:
Alessandro Bono 2023-01-15 14:31:08 +01:00 committed by Marge Bot
parent b4676f0e9e
commit 552d2172bc

View File

@ -512,13 +512,13 @@ export const Dash = GObject.registerClass({
}
_createAppItem(app) {
let item = new DashItemContainer();
let appIcon = new DashIcon(app);
appIcon.connect('menu-state-changed', (o, opened) => {
this._itemMenuStateChanged(item, opened);
});
let item = new DashItemContainer();
item.setChild(appIcon);
// Override default AppIcon label_actor, now the