mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-20 13:26:02 +00:00
A Stores section (rail, under Games; Setup › Stores gate) with each store's sign-in, library, storefront shelves and a download queue. Each store has two tabs, Store and Library, and Library filters to All or Installed; libraries open from a saved copy and refresh in the background, with install sizes on every card. Games install to internal storage, or a card chosen at Install time, and are registered in the Steam client as non-Steam games, so they launch through Steam and droiddeck-proton from either the front end or the client. - Downloads: GOG, Epic and Amazon engines in Rust (app/src/main/rust/stores, built by cargo-ndk, nothing compiled in the tree). One adaptive fetch core with a latency brake, stalled-host handoff and every CDN a store offers. Per-stage progress, pause/resume, two-step cancel that deletes, failed downloads kept for retry, a foreground service with Wi-Fi and wake locks and notification controls. - Games tab: store source chips (Steam, GOG, Epic, Amazon, Custom) and store art. - Epic: per-launch exchange code from the app and from Steam's Play button, "Epic sign-in (EOS)", "Launch offline", and a game's web links opened in Android's browser for EOS consent. The EOS overlay crashed games and is left out. - Cloud saves (GOG, Epic): pulled before launch, pushed after the game or the session ends, no upload before a first download, conflicts never overwritten, backups both ways. - Logs: every store line redacted; the engine log goes to daily files.
39 lines
1.9 KiB
Kotlin
39 lines
1.9 KiB
Kotlin
package com.droiddeck.launcher
|
|
|
|
import android.app.Application
|
|
import com.droiddeck.launcher.runtime.BwrapSpawner
|
|
import com.droiddeck.launcher.session.CrashHandler
|
|
import com.droiddeck.launcher.session.GpuClockPin
|
|
|
|
/**
|
|
* Process-wide setup: the crash handler, so a session's folder is finished even when we die, and
|
|
* the GPU clock pin cleared in case a killed process left it set, and the socket Flatpak's
|
|
* sandboxes are started through (BwrapSpawner).
|
|
*/
|
|
class App : Application() {
|
|
override fun attachBaseContext(base: android.content.Context) =
|
|
super.attachBaseContext(com.droiddeck.launcher.core.AppLanguage.wrap(base))
|
|
|
|
override fun onConfigurationChanged(newConfig: android.content.res.Configuration) {
|
|
super.onConfigurationChanged(newConfig)
|
|
com.droiddeck.launcher.core.AppLanguage.systemChanged(newConfig)
|
|
}
|
|
|
|
override fun onCreate() {
|
|
super.onCreate()
|
|
CrashHandler.install(this)
|
|
// Before anything else touches the session prefs, so the first session already runs in Deck mode.
|
|
com.droiddeck.launcher.session.SessionPrefs.settleDeckModeDefault(this)
|
|
com.droiddeck.launcher.session.SessionPrefs.settleGpuDriverMode(this)
|
|
com.droiddeck.launcher.update.AppUpdates.init(this)
|
|
GpuClockPin.clearLeftover(this)
|
|
BwrapSpawner.start(this)
|
|
com.droiddeck.launcher.frontend.GameFileSync.start(this)
|
|
// The game stores the Stores section can talk to; the native engine loads only when one needs it.
|
|
com.droiddeck.launcher.stores.StoresState.init(this)
|
|
com.droiddeck.launcher.stores.StoresState.register(com.droiddeck.launcher.stores.gog.GogBackend)
|
|
com.droiddeck.launcher.stores.StoresState.register(com.droiddeck.launcher.stores.epic.EpicBackend)
|
|
com.droiddeck.launcher.stores.StoresState.register(com.droiddeck.launcher.stores.amazon.AmazonBackend)
|
|
}
|
|
}
|