Skip to content

fix: match app language of the string resource in SteamService - #1817

Merged
utkarshdalal merged 2 commits into
utkarshdalal:masterfrom
joshuatam:fix/steamservice-match-app-language
Aug 17, 2026
Merged

fix: match app language of the string resource in SteamService#1817
utkarshdalal merged 2 commits into
utkarshdalal:masterfrom
joshuatam:fix/steamservice-match-app-language

Conversation

@joshuatam

@joshuatam joshuatam commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Description

Since #1775 , downloadInfo is now showing the depot information from string resources, when the OS is chinese and the app is english, it will show chinese in the string. This fix it to match app language to SteamService.

Recording

screen-20260814-234155.1.mp4

Type of Change

  • Bug fix
  • Performance / stability improvement
  • Compatibility improvements
  • Other (requires prior approval)

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.
  • This change aligns with the current project scope (core functionality, stability, or performance). If not, it has been explicitly approved beforehand.
  • I have attached a recording of the change.
  • I have read and agree to the contribution guidelines in CONTRIBUTING.md.

Summary by cubic

Applies the app-selected language in SteamService during attachBaseContext so its string resources (e.g., downloadInfo/depot text) follow the app locale instead of the device locale. Previously, with OS Chinese and app English, downloadInfo used the OS language; now it matches the app.

  • Review by running with mismatched OS/app locales and verifying SteamService strings follow the app language.
  • No API/data changes or migrations.

Written for commit de203c3. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • New Features
    • Added support for applying the configured application language when initializing the service.
    • Service-related content now respects the selected locale.

@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: ca04165d-184f-494d-b14e-d296b0bb7a94

📥 Commits

Reviewing files that changed from the base of the PR and between 337d243 and de203c3.

📒 Files selected for processing (1)
  • app/src/main/java/app/gamenative/service/SteamService.kt
🚧 Files skipped from review as they are similar to previous changes (1)
  • app/src/main/java/app/gamenative/service/SteamService.kt

Included review availability: Your plan includes up to 8 reviews per rolling hour; 7 remain after this review.


📝 Walkthrough

Walkthrough

SteamService now applies the configured application language in attachBaseContext before passing the localized context to the superclass.

Changes

Locale-aware service context

Layer / File(s) Summary
Apply configured locale during service startup
app/src/main/java/app/gamenative/service/SteamService.kt
SteamService initializes PrefManager, reads appLanguage, applies it through LocaleHelper, and attaches the localized context.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to de203

This localized change makes SteamService display string resources in the app-selected language instead of the device language; no actionable merge-blocking risk remains beyond normal checks and review.

Suggested reviewers: utkarshdalal

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly identifies the main change: matching SteamService string resources to the app language.
Description check ✅ Passed The description explains the bug and fix, includes a recording, selects bug fix, and completes all checklist items.
✨ 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.

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

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 1 file

Re-trigger cubic

@utkarshdalal
utkarshdalal merged commit d667313 into utkarshdalal:master Aug 17, 2026
3 checks passed
@utkarshdalal

Copy link
Copy Markdown
Owner

Looks good and nicely aligned with legendary.

Main issue: the keep-alive doesn't actually save the exit sync. It runs in viewModelScope, so swiping the app away cancels it anyway and now EpicService is left running with nothing to stop it. The sync needs to run in a scope that outlives the ViewModel (e.g. the service's own scope), with the service stopping itself when work finishes.

Also, downloadChunksParallel holds every decompressed chunk in memory. for the save-heavy games this targets that's an OOM risk. In resolveConflict you only need the chunks referenced by toDownload files, and checking completeness against just those also stops downloadSuccess going false (and the sync timestamp never updating) over chunks we didn't need.

@joshuatam
joshuatam deleted the fix/steamservice-match-app-language branch August 17, 2026 23:28
otufaohumanoide added a commit to otufaohumanoide/GameNative that referenced this pull request Aug 18, 2026
…omendações (utkarshdalal#1828), download externo (utkarshdalal#1785), idioma (utkarshdalal#1817), popups (utkarshdalal#1827), README (utkarshdalal#1826)

Conflitos resolvidos:
- README.md: mantém o README do fork (atribuição librashader + build do fork)
- LibraryScreen.kt: mantém os dois imports (Dispatchers + PostHog)
- LibraryListCard.kt: combina o teaser de recomendação do upstream (utkarshdalal#1828) com
  os badges do fork (ShaderActiveBadge/ProfileOverrideBadge, specs M4/E) —
  badges só em jogos reais, teaser mostra o ícone AutoAwesome

Verificado arquivo por arquivo: nenhum arquivo de shader ou gamepad é alterado
por este merge (catalog.json, VulkanLibrashader, PerGameShaderStore, hub de
gamepad intactos).

LSFG (utkarshdalal#1822): liblsfg-vk-layer.so movida de assets/ para jniLibs; LsfgVkManager
reconciliado (cópia de nativeLibraryDir, manifest segue em assets). Intermediário
stale de assets limpo (gotcha AGENTS.md) — APK contém uma única cópia da .so.

Validação: assembleModernDebug OK (3 ABIs librashader), 218 testes JVM verdes.
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.

3 participants