Skip to content

Skip Glide's manifest parsing and respond to memory-pressure callbacks - #179

Merged
doubleangels merged 1 commit into
mainfrom
dev
Oct 3, 2026
Merged

doubleangels merged 1 commit into
mainfrom
dev

Conversation

@doubleangels

Copy link
Copy Markdown
Owner

Summary

  • Add Glide's annotation processor and an empty AppGlideModule with manifest parsing turned off, so the first Glide.get() call (the first thumbnail load in Clean/Scan/Convert) no longer falls back to scanning the manifest via PackageManager and reflection for legacy module declarations that don't exist in this app.
  • Wire RedactApplication.onTrimMemory/onLowMemory through to Glide, so its memory cache and bitmap pool release proactively under system memory pressure instead of only shrinking once the process is killed outright.

Test plan

  • Confirm a clean release build picks up the generated GeneratedAppGlideModule (first Glide call should no longer hit manifest parsing)
  • Spot-check thumbnail loading in Clean/Scan/Convert still works as before
  • Trigger a simulated low-memory state (e.g. adb shell am send-trim-memory) and confirm no crash

🤖 Generated with Claude Code

https://claude.ai/code/session_01KUuhuB3pkJmPUmtdpqPxJp


Generated by Claude Code

Glide had no annotation-processor-generated AppGlideModule, so the
first Glide.get() call (the first thumbnail load in Clean/Scan/
Convert, not app launch itself) fell back to scanning the manifest
via PackageManager and reflection for legacy module declarations --
overhead with no purpose here, since none are declared. Add the
glide-compiler annotation processor and an empty AppGlideModule with
manifest parsing turned off, per Glide's own documented guidance.

Also wire RedactApplication.onTrimMemory/onLowMemory through to
Glide, so its memory cache and bitmap pool release proactively under
system memory pressure instead of only shrinking once the process is
killed outright.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KUuhuB3pkJmPUmtdpqPxJp
@doubleangels
doubleangels merged commit 15d1829 into main Oct 3, 2026
3 checks passed
doubleangels pushed a commit that referenced this pull request Oct 3, 2026
This reverts commit 15d1829, reversing
changes made to e78dace.
doubleangels pushed a commit that referenced this pull request Oct 5, 2026
main reverted PRs #178 and #179 (which dev still contains). Keeping dev's
version re-lands that work together with this branch's changes.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0195Wi7kaBCgyRx7BUL4zxVP
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants