Skip to content

fix: remove 30s brightness blackout from ambient download overlay#1086

Merged
utkarshdalal merged 1 commit intoutkarshdalal:masterfrom
xXJSONDeruloXx:fix/ambient-dl-no-blackout
Apr 5, 2026
Merged

fix: remove 30s brightness blackout from ambient download overlay#1086
utkarshdalal merged 1 commit intoutkarshdalal:masterfrom
xXJSONDeruloXx:fix/ambient-dl-no-blackout

Conversation

@xXJSONDeruloXx
Copy link
Copy Markdown
Contributor

@xXJSONDeruloXx xXJSONDeruloXx commented Apr 3, 2026

Description

@Producdevity for the minimal dl progress thing, is it supposed to fade out to fully black after like 30 sec? id prefer we just keep having the progress bar personally, or, when i tap once then go back to black with moving bar, tap one more time to get all the way back to full app. what do you think

Producdevity

Thinking about it, I agree. We probably can get rid of the full blackout after 30 seconds. The bar and texts do shift slightly so showing those even for a long period of time shouldn’t burn-in OLED screens

this is the pr which does the agreed upon, remove the fade to full black but preserve the minimalist fade out while downloading after 10 sec.

Recording

imagine in your minds eye, the thing that was happening, not happening now

Checklist

  • If I have access to #code-changes, I have discussed this change there and it has been green-lighted. If I do not have access, I have still provided clear context in this PR. If I skip both, I accept that this change may face delays in review, may not be reviewed at all, or may be closed.
  • I have attached a recording of the change.
  • I have read and agree to the contribution guidelines in CONTRIBUTING.md.

Summary by CodeRabbit

  • Bug Fixes
    • Removed automatic screen brightness dimming behavior from the ambient download overlay. The overlay now manages visual appearance and user interactions only, without adjusting system brightness settings.

The BRIGHTNESS_DIM_DELAY_MS / MIN_BRIGHTNESS logic would tank screen
brightness to 0.01f after 30 seconds of idle, effectively blacking out
the display. Since the bar and texts drift slightly (OLED burn-in safe),
there's no reason to kill the screen — just keep the ambient overlay
visible indefinitely until the user wakes it or the download finishes.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 3, 2026

📝 Walkthrough

Walkthrough

This PR removes brightness management functionality from the ambient download overlay feature. The BrightnessManager instance, dimming/restore logic, and related constants (BRIGHTNESS_DIM_DELAY_MS, MIN_BRIGHTNESS) are deleted across two files. The overlay now handles only visual state and interaction timing without system brightness control.

Changes

Cohort / File(s) Summary
Brightness Management Removal
app/src/main/java/app/gamenative/ui/screen/library/components/ambient/AmbientDownloadOverlay.kt
Removed BrightnessManager instance initialization, coroutine-driven brightness dimming/restoration tied to isIdle state, and DisposableEffect cleanup logic for brightness restoration.
Constants Cleanup
app/src/main/java/app/gamenative/ui/screen/library/components/ambient/AmbientModeConstants.kt
Removed BRIGHTNESS_DIM_DELAY_MS and MIN_BRIGHTNESS constants no longer required by the overlay.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

  • PR #1017: Directly reverses the brightness-dimming logic and constants that were previously added to the ambient mode implementation.

Poem

🐰 The dimmer's gone, the light stays true,
No darkened screens for this bright crew,
The overlay shines clean and free,
Ambient bliss, naturally! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description includes the required sections (Description, Recording, Checklist) but the Recording section contains only a joking placeholder, and two critical checklist items remain unchecked. Provide an actual recording/GIF demonstrating the change and ensure all required checklist items are marked complete before merging.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main change: removing the 30-second brightness blackout functionality from the ambient download overlay.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 2 files

@utkarshdalal utkarshdalal merged commit 39fcb26 into utkarshdalal:master Apr 5, 2026
3 checks passed
@xXJSONDeruloXx xXJSONDeruloXx deleted the fix/ambient-dl-no-blackout branch April 5, 2026 02:57
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