diff --git a/CHANGELOG.md b/CHANGELOG.md index c38c7d7a1..8add9aae7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ - Add users option to config files; have a default config file ([#1649](../../pull/1649)) - Remove no longer used code; adjust item list slightly ([#1651](../../pull/1651)) - Reduce updates when showing item lists; add a waiting spinner ([#1653](../../pull/1653)) +- Update item lists check for large images when toggling recurse ([#1654](../../pull/1654)) ### Bug Fixes diff --git a/girder/girder_large_image/web_client/views/itemList.js b/girder/girder_large_image/web_client/views/itemList.js index 22c187d0c..f506c87a6 100644 --- a/girder/girder_large_image/web_client/views/itemList.js +++ b/girder/girder_large_image/web_client/views/itemList.js @@ -162,6 +162,10 @@ wrap(ItemListWidget, 'render', function (render) { const oldPages = this._totalPages; const pages = Math.ceil(this.collection.getTotalCount() / this.collection.pageLimit); this._totalPages = pages; + // recheck if this has large images + this._hasAnyLargeImage = !!_.some(this.collection.toArray(), function (item) { + return item.has('largeImage'); + }); this._inFetch = false; itemListRender.apply(this, _.rest(arguments)); if (oldPages !== pages || this.collection.offset !== this.collection.size()) {