Skip to content

AutoExpand

Automatically expands notifications before they pop up.

GitHub Downloads
4,628
GitHub Stars
38

Overview

An app that works on the Android UI layer and uses a hook to change the notification function's behaviour, making it open the notification before it appears to the user, with the ability to exclude apps and let them behave normally.

Tech stack

Features

Auto-expand notifications

UX

Full notification content before it appears.

Notifications expand before they appear to the user to show the full notification content. The tool's strength is showing OTP codes and long messages.

Snapper

UX

Float any image on screen.

A Quick Settings shortcut that opens Snapper to float any image on the screen. It helps move text into fields that do not support paste.

Deep-dive

The module registers separate hooks for SystemUI and the system framework, with each scope responsible for one surface. Notification lookups resolve package names defensively and every failure is swallowed, so an unsupported build loses a tweak rather than stability. Settings are cached briefly and read from an on-device provider, keeping the hooked processes independent of the settings app.

Kotlin
private fun getNotificationPackage(row: Any): String? {
    return try {
        val entry = XposedHelpers.callMethod(row, "getEntry")
        val sbn = XposedHelpers.callMethod(entry, "getSbn")
        XposedHelpers.callMethod(sbn, "getPackageName") as? String
    } catch (_: Throwable) {
        null
    }
}