iconGrid: Don't update pages in vfunc_allocate()

vfunc_allocate() is a hot path, and we don't want to do expensive stuff
there, so avoid updating the pages, which seems unnecessary anyway.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
This commit is contained in:
Jonas Dreßler 2021-02-23 20:16:00 +01:00 committed by Marge Bot
parent 0978b87e65
commit 0fd394d4ca

View File

@ -775,8 +775,6 @@ var IconGridLayout = GObject.registerClass({
if (this._pageWidth === 0 || this._pageHeight === 0)
throw new Error('IconGridLayout.adaptToSize wasn\'t called before allocation');
this._updatePages();
const isRtl =
Clutter.get_default_text_direction() === Clutter.TextDirection.RTL;
const childSize = this._getChildrenMaxSize();