Trigger cache eviction after infinite scroll page drain
Prevents unbounded cache growth during long infinite scroll sessions. Runs after each batch of posts finishes loading.
This commit is contained in:
parent
39733e4865
commit
81b609f55e
@ -909,8 +909,9 @@ class BooruApp(QMainWindow):
|
||||
if self._append_queue:
|
||||
QTimer.singleShot(50, self._drain_append_queue)
|
||||
else:
|
||||
# All done — unlock loading and prefetch
|
||||
# All done — unlock loading, evict, prefetch
|
||||
self._loading = False
|
||||
self._auto_evict_cache()
|
||||
if self._db.get_setting_bool("prefetch_adjacent"):
|
||||
self._prefetch_adjacent(idx)
|
||||
# Check if still at bottom or content doesn't fill viewport
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user