Skip to content

Add optional post-unlock Mindful Launch check and harden Gemini target detection - #106

Draft
natakhot271 wants to merge 2 commits into
aload0:mainfrom
natakhot271:main
Draft

natakhot271 wants to merge 2 commits into
aload0:mainfrom
natakhot271:main

Conversation

@natakhot271

Copy link
Copy Markdown
Contributor

Summary

  • Optional post-unlock Mindful Launch check (MindfulLaunchManager, MindfulLaunchSettingsScreen, BlockerService):
    • Adds a Phone Unlock toggle in Mindful Launch settings (off by default) to trigger a foreground Mindful Launch check on Intent.ACTION_USER_PRESENT.
    • Treats post-unlock re-entry as a window-state transition so a preceding content-change event cannot debounce away the prompt.
  • Gemini target resolution and debounce hardening (MindfulLaunchTargetEvaluator, BlockerService):
    • Matches additional Gemini Activity namespaces (assistant.surfaces.voice.robin and apps.bard) hosted under com.google.android.googlequicksearchbox.
    • Preserves the tracked foreground Activity class name across transient framework/Material overlays and widget content-change events, resetting enforcement whenever either the raw package or resolved target package changes.
    • Keys app-check debouncing (lastCheckedTargetPackage) and foreground enforcement (enforcedForegroundPackage) on the resolved target package, and prevents content-change events from suppressing TYPE_WINDOW_STATE_CHANGED checks.
  • Unit tests (MindfulLaunchTargetEvaluatorTest):
    • Adds tests for the expanded Gemini Activity hints, foreground class-name tracking across dialogs and navigation, and debounce behavior between content and window-state events.

@natakhot271
natakhot271 force-pushed the main branch 2 times, most recently from a02784f to 9f75f13 Compare November 22, 2026 05:15
@natakhot271
natakhot271 force-pushed the main branch 2 times, most recently from 537d029 to 1c2ad82 Compare November 22, 2026 06:01
…ervice

Match additional Gemini activity namespaces in MindfulLaunchTargetEvaluator, track foreground Activity class name across transient overlays and content events, key app-check debouncing and enforcement on the resolved target package without letting content events suppress window-state transitions, and add unit tests.
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.

1 participant