Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
c441594
ADFA-40: add :security module with Instant Hide gesture detectors
davidschachterADFA Oct 13, 2026
c788145
ADFA-40: add Instant Hide preference flag and Security settings toggle
davidschachterADFA Oct 13, 2026
8ce92df
ADFA-40: add the Code Breaker cryptogram disguise, aliases, and redirect
davidschachterADFA Oct 13, 2026
af31299
ADFA-40: spotless reformat EdgeToEdgeIDEActivity.kt (no functional ch…
davidschachterADFA Oct 13, 2026
275aeb3
ADFA-40: wire the Instant Hide triggers into the IDE
davidschachterADFA Oct 13, 2026
5af8d85
ADFA-40: move Instant Hide strings to :resources; add module docs
davidschachterADFA Oct 13, 2026
bef5d7d
ADFA-40: trigger face-down hide on orientation alone
davidschachterADFA Oct 13, 2026
3f798c6
ADFA-40: fix README face-down description (orientation only)
davidschachterADFA Oct 13, 2026
5131c64
ADFA-40: close the deep-link concealment bypass
davidschachterADFA Oct 13, 2026
922c17d
ADFA-40: apply FLAG_SECURE immediately when Instant Hide is toggled
davidschachterADFA Oct 13, 2026
cecc3f2
ADFA-6510: Instant Wipe PR1 -- WipeManager engine + secure shredder +…
davidschachterADFA Oct 13, 2026
59331d7
ADFA-6510: Instant Wipe PR2 -- CircleGestureDetector + geometry tests
davidschachterADFA Oct 13, 2026
00ece25
ADFA-6510: Instant Wipe PR3 (1/2) -- arm toggle + destructive confirm…
davidschachterADFA Oct 13, 2026
5bca548
ADFA-6510: Instant Wipe PR3 (2/2) -- safe gesture practice overlay
davidschachterADFA Oct 13, 2026
f95fb0b
ADFA-6510: Instant Wipe PR4 (1/2) -- wipe orchestration (inert; no tr…
davidschachterADFA Oct 13, 2026
ad4699c
ADFA-6510: Instant Wipe PR4 (2/2) -- wire the circle gesture on all s…
davidschachterADFA Oct 13, 2026
e2ee8c6
ADFA-6510: mount SecurityController on the terminal (hide + FLAG_SECU…
davidschachterADFA Oct 13, 2026
7030f04
ADFA-6510: Instant Wipe PR5 -- tamper tripwire + neutralization-on-la…
davidschachterADFA Oct 13, 2026
fd7ff41
ADFA-6510: tamper neutralizes instead of re-wiping
davidschachterADFA Oct 13, 2026
5f54f03
ADFA-6510: close the splash-screen concealment leak on the stealth la…
davidschachterADFA Oct 13, 2026
4801fd0
ADFA-6510: add an Instant Hide gesture rehearsal (parity with Instant…
davidschachterADFA Oct 13, 2026
b02dd6b
ADFA-6510: address self-review findings (F01-F05)
davidschachterADFA Oct 13, 2026
f94c610
ADFA-6510: address self-review nits (F06-F09)
davidschachterADFA Oct 13, 2026
d87b55a
Merge branch 'stage' into feature/ADFA-40-instant-hide
davidschachterADFA Oct 13, 2026
c53d755
Merge origin/feature/ADFA-40-instant-hide into feature/ADFA-6510-inst…
davidschachterADFA Oct 13, 2026
af5918b
ADFA-6510: wipe-aware launcher-alias reconcile (folds in ADFA-6507)
davidschachterADFA Oct 13, 2026
a7b0847
ADFA-6510: pin the ADFA-6507 alias ordering + reconcile with unit tests
davidschachterADFA Oct 13, 2026
774498c
ADFA-6510: address PR #2137 review (F01 exit guard, F02 marker ordering)
davidschachterADFA Oct 14, 2026
abfb237
Merge branch 'stage' into feature/ADFA-40-instant-hide
davidschachterADFA Oct 28, 2026
88d1a7d
Merge branch 'feature/ADFA-40-instant-hide' into feature/ADFA-6510-in…
davidschachterADFA Oct 28, 2026
6452f50
Merge branch 'stage' into feature/ADFA-40-instant-hide
davidschachterADFA Oct 29, 2026
0da3e75
Merge branch 'feature/ADFA-40-instant-hide' into feature/ADFA-6510-in…
davidschachterADFA Oct 29, 2026
7db4744
Merge branch 'stage' into feature/ADFA-40-instant-hide
davidschachterADFA Oct 29, 2026
6b127c0
Merge branch 'feature/ADFA-40-instant-hide' into feature/ADFA-6510-in…
davidschachterADFA Oct 29, 2026
624b5e7
Merge branch 'stage' into feature/ADFA-40-instant-hide
davidschachterADFA Oct 29, 2026
e157811
style: spotless reformat CrashHandlerActivity, no functional change
davidschachterADFA Oct 29, 2026
7883d86
ADFA-40: keep the launcher component name so pinned icons survive
davidschachterADFA Oct 29, 2026
f724770
ADFA-40: show the stealth icon on the disguise's Recents card
davidschachterADFA Oct 29, 2026
7fc6218
ADFA-40: mount Instant Hide on every activity
davidschachterADFA Oct 29, 2026
18006bb
Merge remote-tracking branch 'origin/feature/ADFA-40-instant-hide' in…
davidschachterADFA Oct 29, 2026
a75e2e0
Merge branch 'feature/ADFA-40-instant-hide' into feature/ADFA-6510-in…
davidschachterADFA Oct 29, 2026
87dfd8f
ADFA-6510: keep a wiped install the disguise on every entry point
davidschachterADFA Oct 29, 2026
732c2fc
ADFA-6510: wipe the relocated build output and Quick Build's scratch
davidschachterADFA Oct 30, 2026
ba954e5
ADFA-6510: never follow a symbolic link out of a wipe target
davidschachterADFA Oct 30, 2026
c09d360
ADFA-40: hide once per screen-off broadcast
davidschachterADFA Oct 30, 2026
ee9591d
Merge remote-tracking branch 'origin/feature/ADFA-40-instant-hide' in…
davidschachterADFA Oct 30, 2026
3e5d00a
ADFA-40: keep the disguise up after a hide; restart the idle minute o…
davidschachterADFA Oct 30, 2026
e6b0a8f
Merge feature/ADFA-40-instant-hide into feature/ADFA-6510-instant-wipe
davidschachterADFA Oct 30, 2026
cad0788
ADFA-6510: start the wipe's disguise and the stealth splash's through…
davidschachterADFA Oct 30, 2026
b0ce82a
ADFA-6510: log wipe target paths in a dry run only
davidschachterADFA Oct 30, 2026
439c54f
ADFA-40: document that the app's own name still shows while hidden
davidschachterADFA Oct 30, 2026
bed36d6
Merge feature/ADFA-40-instant-hide into feature/ADFA-6510-instant-wipe
davidschachterADFA Oct 30, 2026
5099486
ADFA-6510: repair a launcher left with no icon or with both icons
davidschachterADFA Oct 30, 2026
bf132b0
ADFA-6510: stop other apps from starting StealthSplashActivity
davidschachterADFA Oct 30, 2026
b6946a0
Merge feature/ADFA-40-instant-hide into feature/ADFA-6510-instant-wipe
davidschachterADFA Oct 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ Strategy: **layer-and-subsystem based**, not feature-by-feature. The Gradle buil
| Shell | `termux:{termux-app,termux-shared,termux-view,termux-emulator}` | Embedded Termux shell and terminal. |
| Plugin system | `plugin-api`, `plugin-api:plugin-builder`, `plugin-manager` | In-app plugin SDK + manager — `AndroidManifest.xml` `<meta-data>` contract, permissions, extensions. See [plugin-api.md](docs/plugin-api.md) for the API surface & compatibility policy. |
| On-device AI | `llama-api`, `llama-impl` | llama.cpp integration, shipped as a per-flavor native AAR. |
| Security | `security` | Instant Hide emergency disguise (ADFA-40): gesture/sensor triggers mounted on the IDE base activity swap the app to a "Code Breaker" cryptogram game and mask it in Recents. Renders in Views, not Compose — a documented [ADR 0009](docs/adr/0009-jetpack-compose-for-new-ui.md) exception (see `security/README.md`). |
| Security | `security` | Instant Hide emergency disguise (ADFA-40) and Instant Wipe self-destruct (ADFA-6510): gesture/sensor triggers mounted on the IDE base activity swap the app to a "Code Breaker" cryptogram game and mask it in Recents; a circular-sweep gesture irreversibly wipes the workspace and neutralizes the app to that disguise. The `:app`-owned destroy/teardown is reached across the module boundary via the `WipeService` interface. Renders in Views, not Compose — a documented [ADR 0009](docs/adr/0009-jetpack-compose-for-new-ui.md) exception (see `security/README.md`). |
| Cross-cutting | `eventbus`, `eventbus-android`, `eventbus-events`, `common`, `common-ui`, `common-compose`, `logger`, `resources`, `preferences`, `shared` | Shared infra and the event bus. `common-compose` holds the Compose theming any module can opt into (see [ADR 0009](docs/adr/0009-jetpack-compose-for-new-ui.md)); it is a leaf so modules that aren't Compose pay nothing. |
| Testing | `testing:{android,unit,lsp,tooling,common}` | Shared test harnesses, split by what's under test. |

Expand Down
25 changes: 19 additions & 6 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,8 @@
<!--
LauncherActivity has no launcher intent-filter of its own: the launcher identity is carried
by the activity-aliases below so Instant Hide (ADFA-40) can swap the app name/icon to the
"Code Breaker" disguise by toggling which alias is enabled. All aliases target LauncherActivity.
"Code Breaker" disguise by toggling which alias is enabled. The default alias targets
LauncherActivity; the stealth aliases target StealthSplashActivity.
The default alias keeps the launcher activity's name from before Instant Hide,
.activities.SplashActivity, so a home-screen icon pinned to that component survives the
update on every launcher.
Expand All @@ -91,6 +92,18 @@
android:exported="true"
android:theme="@style/AppTheme.Splash" />

<!--
Stealth launcher entry: the stealth aliases below target this instead of LauncherActivity so
the splash (painted by the OS from the activity theme before app code runs) shows no Code On
The Go logo. It forwards straight to the cryptogram. See ADFA-6510.
Not exported: the aliases are, so the launcher still opens it, but another app cannot. Opened
by another app, it would close the IDE, since showing the disguise removes the IDE's tasks.
-->
<activity
android:name=".activities.StealthSplashActivity"
android:exported="false"
android:theme="@style/AppTheme.Splash.Stealth" />
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved

<activity-alias
android:name=".activities.SplashActivity"
android:targetActivity=".activities.LauncherActivity"
Expand All @@ -107,7 +120,7 @@

<activity-alias
android:name=".StealthAliasActivity1"
android:targetActivity=".activities.LauncherActivity"
android:targetActivity=".activities.StealthSplashActivity"
android:label="@string/stealth_app_name"
android:icon="@drawable/ic_launcher_stealth_1"
android:roundIcon="@drawable/ic_launcher_stealth_1"
Expand All @@ -121,7 +134,7 @@

<activity-alias
android:name=".StealthAliasActivity2"
android:targetActivity=".activities.LauncherActivity"
android:targetActivity=".activities.StealthSplashActivity"
android:label="@string/stealth_app_name"
android:icon="@drawable/ic_launcher_stealth_2"
android:roundIcon="@drawable/ic_launcher_stealth_2"
Expand All @@ -135,7 +148,7 @@

<activity-alias
android:name=".StealthAliasActivity3"
android:targetActivity=".activities.LauncherActivity"
android:targetActivity=".activities.StealthSplashActivity"
android:label="@string/stealth_app_name"
android:icon="@drawable/ic_launcher_stealth_3"
android:roundIcon="@drawable/ic_launcher_stealth_3"
Expand All @@ -149,7 +162,7 @@

<activity-alias
android:name=".StealthAliasActivity4"
android:targetActivity=".activities.LauncherActivity"
android:targetActivity=".activities.StealthSplashActivity"
android:label="@string/stealth_app_name"
android:icon="@drawable/ic_launcher_stealth_4"
android:roundIcon="@drawable/ic_launcher_stealth_4"
Expand All @@ -163,7 +176,7 @@

<activity-alias
android:name=".StealthAliasActivity5"
android:targetActivity=".activities.LauncherActivity"
android:targetActivity=".activities.StealthSplashActivity"
android:label="@string/stealth_app_name"
android:icon="@drawable/ic_launcher_stealth_5"
android:roundIcon="@drawable/ic_launcher_stealth_5"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import android.os.Bundle
import com.itsaky.androidide.app.configuration.CpuArch
import com.itsaky.androidide.app.configuration.IDEBuildConfigProvider
import com.itsaky.androidide.security.InstantHide
import com.itsaky.androidide.security.LauncherAliasManager
import com.itsaky.androidide.ui.showLowStorageDialog
import com.itsaky.androidide.utils.FeatureFlags
import com.itsaky.androidide.utils.hasEnoughStorageAvailable
Expand All @@ -36,8 +37,13 @@ class LauncherActivity : Activity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)

// Instant Hide (ADFA-40): if the disguise is engaged, go straight to it before any IDE UI
// is shown. The state persists across restarts/reboots until the user performs the exit gesture.
// Instant Hide (ADFA-40) and Instant Wipe (ADFA-6510): while the disguise is engaged, or once the
// install is wiped -- or its markers were stripped by clearing app data while the stealth alias
// persists (the tamper fingerprint) -- go straight to the disguise before any IDE UI. Tamper
// deliberately does NOT re-run the wipe: the signature cannot tell a prior Instant Wipe from a
// plain Instant Hide whose data was cleared, so re-wiping could destroy work the user never meant
// to wipe. Staying the disguise still defeats the tamper. The checks run on the main thread by
// design and MUST complete before any IDE UI could be shown (F08).
if (InstantHide.redirectIfHidden(this)) return

if (!hasEnoughStorageAvailable()) {
Expand All @@ -52,6 +58,11 @@ class LauncherActivity : Activity() {
exitProcess(0)
}

// ADFA-6507 (wipe-aware reconcile): launching the real IDE -- not hidden, wiped, or tampered (all
// early-returned above), so the default alias must be the only launcher icon. Heal a stealth alias
// left stuck by a partial swap, before it could later read as the tamper fingerprint.
LauncherAliasManager.reconcile(this, disguiseActive = false)

startActivity(Intent(this, OnboardingActivity::class.java))
finish()
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*
* This file is part of AndroidIDE.
*
* AndroidIDE is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* AndroidIDE is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with AndroidIDE. If not, see <https://www.gnu.org/licenses/>.
*/

package com.itsaky.androidide.activities

import android.app.Activity
import android.os.Bundle
import com.itsaky.androidide.security.InstantHide

/**
* Launcher entry for the stealth "Code Breaker" activity-aliases (ADFA-40 / ADFA-6510).
*
* Separate from [LauncherActivity] purely so its splash theme can avoid the real Code On The Go
* branding: the OS paints the system starting window from the launched activity's theme before any
* app code runs, so routing the stealth aliases through [LauncherActivity] (whose `AppTheme.Splash`
* shows the IDE logo) flashed that logo for ~200ms before the disguise appeared. A stealth alias is
* only ever enabled while the disguise is engaged, so tapping it must show only the game -- this
* forwards straight to the cryptogram, never the IDE, reusing a running one so the puzzle survives.
*/
class StealthSplashActivity : Activity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
// The lifecycle callback has already shown the disguise if the app is hidden or neutralized.
if (!isFinishing) InstantHide.showDisguise(this, InstantHide.disguiseIntent(this))
}
}
168 changes: 168 additions & 0 deletions app/src/main/java/com/itsaky/androidide/app/AppWipeService.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
/*
* This file is part of AndroidIDE.
*
* AndroidIDE is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* AndroidIDE is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with AndroidIDE. If not, see <https://www.gnu.org/licenses/>.
*/

package com.itsaky.androidide.app

import android.app.Activity
import android.content.Context
import android.content.Intent
import android.util.Log
import android.widget.Toast
import androidx.annotation.VisibleForTesting
import com.itsaky.androidide.BuildConfig
import com.itsaky.androidide.lookup.Lookup
import com.itsaky.androidide.preferences.internal.GeneralPreferences
import com.itsaky.androidide.preferences.internal.SecurityPreferences
import com.itsaky.androidide.projects.IProjectManager
import com.itsaky.androidide.projects.builder.BuildService
import com.itsaky.androidide.quickbuild.EnvironmentQuickBuildPaths
import com.itsaky.androidide.roomData.recentproject.RecentProjectRoomDatabase
import com.itsaky.androidide.security.InstantHide
import com.itsaky.androidide.security.LauncherAliasManager
import com.itsaky.androidide.security.NeutralizationMarker
import com.itsaky.androidide.security.SecurityOverride
import com.itsaky.androidide.security.WipeManager
import com.itsaky.androidide.security.WipePlan
import com.itsaky.androidide.security.WipeService
import com.itsaky.androidide.security.WipeTeardown
import com.itsaky.androidide.services.builder.BuildOutputLocation
import com.itsaky.androidide.utils.Environment
import com.termux.app.TermuxService
import com.termux.shared.termux.TermuxConstants
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.MainScope
import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext
import java.io.File
import java.util.concurrent.atomic.AtomicBoolean

/**
* The `:app` implementation of [WipeService] (ADFA-6510). It resolves the real on-device paths, tears
* down the IDE's runtime holds, presents the disguise, and runs [WipeManager] on the app-scoped
* coroutine with [Dispatchers.IO] (which outlives the activity it finishes). Honours the
* `/sdcard/Download/CodeOnTheGo.nowipe` dry-run override (debug-only dev/QA scaffold; remove before GA).
*/
class AppWipeService(
private val app: Context,
) : WipeService {
// Guards against a second circle (on the just-shown disguise) starting a concurrent wipe before the
// first finishes blanking the prefs. Never reset: a wipe is terminal (a fresh process re-creates it).
private val wipeStarted = AtomicBoolean(false)

override fun trigger(activity: Activity) {
// The /sdcard/Download/CodeOnTheGo.nowipe override is honoured only in debug builds, so a
// dropped file can never silently no-op a real wipe in a release build (F02).
val dryRun = BuildConfig.DEBUG && SecurityOverride.isWipeDryRun()
if (!wipeStarted.compareAndSet(false, true)) return

// Present the disguise immediately (reuse Instant Hide's presentation): the Code Breaker game
// covers the screen while the destroy pass runs behind it. Shown in dry-run too, so the whole
// flow is exercised; the exit gesture restores it since dry-run writes no marker.
SecurityPreferences.isHiddenStateActive = true
runCatching { LauncherAliasManager.setStealthMode(activity, true) }
// As a hide does: floating windows and notifications outlive the activity and would show the IDE
// over the disguise until the teardown below reaches them.
InstantHide.hideOutsideActivities(app)
InstantHide.showDisguise(activity, InstantHide.newDisguiseIntent(activity))

// File IO + build cancel: off the main thread, on the app scope so it survives the finished activity.
(app as IDEApplication).coroutineScope.launch(Dispatchers.IO) {
runCatching { Environment.init(app) }
val result = WipeManager.wipe(buildPlan(), teardown(dryRun), dryRun) { line -> Log.w(TAG, line) }
if (dryRun) {
// Advisory in dry-run only (QA). A real wipe shows nothing user-visible: a toast would
// pop over the disguise and announce the wipe to anyone watching the seized device (F01).
withContext(Dispatchers.Main) {
Toast
.makeText(
app,
"Instant Wipe dry run: ${result.enumeratedTargets.size} target(s), nothing deleted",
Toast.LENGTH_LONG,
).show()
}
} else {
Log.w(TAG, "Instant Wipe complete")
}
}
}

@VisibleForTesting
internal fun buildPlan(): WipePlan {
val db = app.getDatabasePath(RECENTS_DB)
val dbFiles = listOf(db, File(db.path + "-wal"), File(db.path + "-shm"))
return WipePlan(
// The user's source plus the small Recents DB files (sensitive metadata: project
// names/paths). The DB is closed first in a real wipe (see teardown), so shredding its files
// carries no open-fd hazard. Cache dirs inside each project are fast-deleted (skipDirs) so
// the shred stays fast on a multi-GB workspace.
secureTargets = listOfNotNull(Environment.PROJECTS_DIR) + dbFiles,
secureTargetSkipDirs = setOf("build", ".gradle", ".cg"),
// Bulk regenerable caches. Build output lives outside the projects since ADFA-4930, and
// Quick Build's scratch beside it; both hold the compiled app, and the build output's folder
// names carry the project names.
fastDeleteTargets =
listOfNotNull(Environment.ANDROIDIDE_HOME, Environment.GRADLE_USER_HOME) +
File(app.noBackupFilesDir, BuildOutputLocation.DIR_NAME) +
EnvironmentQuickBuildPaths(app).projectScratchRoot,
markerFiles = listOf(NeutralizationMarker.pipFile(app), NeutralizationMarker.pip2File(app)),
)
}

private fun teardown(dryRun: Boolean): WipeTeardown =
object : WipeTeardown {
override fun stopEverything() {
// Cancel any in-progress Gradle build (async; fire-and-forget). Null when not running.
runCatching {
val build = Lookup.getDefault().lookup(BuildService.KEY_BUILD_SERVICE)
if (build != null && build.isBuildInProgress) build.cancelCurrentBuild()
}
// Stop the Termux session (delivered via startService; the service stops itself).
runCatching {
app.startService(
Intent(app, TermuxService::class.java).apply {
action = TermuxConstants.TERMUX_APP.TERMUX_SERVICE.ACTION_STOP_SERVICE
},
)
}
// Release the open project's in-memory state (does not touch files).
runCatching { IProjectManager.getInstance().destroy() }
// Close the Recents Room DB before its files are shredded, so no connection holds or
// rewrites them. Real wipe only: afterwards the app is neutralized and the IDE -- the
// DB's only user -- never runs again, so the now-closed cached instance is never touched.
// Skipped in dry-run, which must not mutate state (and where the app keeps running).
if (!dryRun) {
runCatching {
val db = RecentProjectRoomDatabase.getDatabase(app, MainScope())
if (db.isOpen) db.close()
}
}
}

override fun resetBookkeeping() {
runCatching { GeneralPreferences.lastOpenedProject = GeneralPreferences.NO_OPENED_PROJECT }
}

override fun clearPreferences() {
SecurityPreferences.clearAll()
}
}

companion object {
private const val TAG = "AppWipeService"
private const val RECENTS_DB = "RecentProject_database"
}
}
6 changes: 6 additions & 0 deletions app/src/main/java/com/itsaky/androidide/app/IDEApplication.kt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ import com.itsaky.androidide.floating.model.DockingManager
import com.itsaky.androidide.handlers.GlitchTipDiagnosticsContext
import com.itsaky.androidide.plugins.manager.core.PluginManager
import com.itsaky.androidide.security.InstantHide
import com.itsaky.androidide.security.WipeService
import com.itsaky.androidide.security.WipeServiceProvider
import com.itsaky.androidide.treesitter.TreeSitter
import com.itsaky.androidide.utils.RecyclableObjectPool
import com.itsaky.androidide.utils.VMUtils
Expand Down Expand Up @@ -66,9 +68,13 @@ const val EXIT_CODE_CRASH = 1
class IDEApplication :
BaseApplication(),
Configuration.Provider,
WipeServiceProvider,
Application.ActivityLifecycleCallbacks by ActivityLifecycleCallbacksDelegate() {
val coroutineScope = MainScope() + CoroutineName("ApplicationScope")

/** Instant Wipe (ADFA-6510) entry point; resolved from `:security` surfaces via this Application. */
override val wipeService: WipeService by lazy { AppWipeService(this) }

internal var uncaughtExceptionHandler: UncaughtExceptionHandler? = null
private var _foregroundActivity = MutableStateFlow<Activity?>(null)

Expand Down
Loading