Skip to content

feat(auto-upload): battery saver, batter optimization indication#16934

Draft
alperozturk96 wants to merge 6 commits intomasterfrom
warn-auto-upload-battery-saver-mode-distinquish-between-os-and-app
Draft

feat(auto-upload): battery saver, batter optimization indication#16934
alperozturk96 wants to merge 6 commits intomasterfrom
warn-auto-upload-battery-saver-mode-distinquish-between-os-and-app

Conversation

@alperozturk96
Copy link
Copy Markdown
Collaborator

@alperozturk96 alperozturk96 commented Apr 28, 2026

The difference between Android's battery saver mode and Nextcloud's app battery optimization mode was confusing. This PR clarifies that if user not has one of it.

Image 1 Image 2 Image 3

Changes

  • Detects battery optimization mode and battery saver mode and indicates both if needed.
  • Adds to the activity XML instead of adapter's first section
  • Fixes showing same banner for each section

@alperozturk96 alperozturk96 linked an issue Apr 28, 2026 that may be closed by this pull request
@github-actions
Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/25058352829/artifacts/6686650006
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@github-actions
Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/25060519592/artifacts/6688365587
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

<string name="auto_upload_delete_dialog_title">Delete auto-upload folder?</string>
<string name="auto_upload_delete_dialog_description">This will remove the folder and auto-upload configuration. Any unfinished uploads will be canceled.</string>
<string name="auto_upload_battery_saver_mode_warning">Auto-upload is paused because Battery Saver is on.</string>
<string name="auto_upload_battery_combined_warning">Auto-upload may be limited:</string>
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

@kra-mo I would like to get your opinion regarding wording.

@alperozturk96
Copy link
Copy Markdown
Collaborator Author

/backport to stable-33.1.x

@github-actions
Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/25094341195/artifacts/6701043178
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@alperozturk96 alperozturk96 marked this pull request as draft April 30, 2026 09:50
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
@alperozturk96 alperozturk96 force-pushed the warn-auto-upload-battery-saver-mode-distinquish-between-os-and-app branch from ab682a4 to 7d06522 Compare May 5, 2026 09:13
@alperozturk96
Copy link
Copy Markdown
Collaborator Author

@kra-mo @tobiasKaminsky

We can directly show native dialog for allow background usage.

we_can_directly_show_native_dialog_for_apps_battery_optimization

We can redirect OS's battery saver page

we_can_redirect_os_battery_saver

Where can we put these actions in banner?

Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 5, 2026

blue-Light-Screenshot test failed, but no output was generated. Maybe a preliminary stage failed.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 5, 2026

Codacy

SpotBugs

CategoryBaseNew
Bad practice3535
Correctness6767
Dodgy code216216
Experimental11
Internationalization77
Malicious code vulnerability22
Multithreaded correctness3434
Performance4242
Security1616
Total420420

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 5, 2026

APK file: https://github.com/nextcloud/android/actions/runs/25368366526/artifacts/6803481556
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

(auto:upload) battery saver detection

2 participants