Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
Sichere ProgrammierungRefreshed repository pull requests page generally available(22.09.2026 um 03:25 Uhr)
Sichere ProgrammierungThe Joy of Learning the Basics Again(22.09.2026 um 03:28 Uhr)
Sichere ProgrammierungZero-Code OpenTelemetry Tracing for Dagster(22.09.2026 um 03:39 Uhr)
Linux Tipps & Hardening`prime-all`(22.09.2026 um 02:28 Uhr)
IT Security Toolsopensoho v0.15.2(22.09.2026 um 03:33 Uhr)
IT Security NachrichtenUS Proposes AI Incident Alert System in Talks With China, Bessent Says(22.09.2026 um 04:01 Uhr)
Sichere ProgrammierungRefreshed repository pull requests page generally available(22.09.2026 um 03:25 Uhr)
Sichere ProgrammierungThe Joy of Learning the Basics Again(22.09.2026 um 03:28 Uhr)
Sichere ProgrammierungZero-Code OpenTelemetry Tracing for Dagster(22.09.2026 um 03:39 Uhr)
Linux Tipps & Hardening`prime-all`(22.09.2026 um 02:28 Uhr)
IT Security Toolsopensoho v0.15.2(22.09.2026 um 03:33 Uhr)
IT Security NachrichtenUS Proposes AI Incident Alert System in Talks With China, Bessent Says(22.09.2026 um 04:01 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

Android App Shortcuts — Launch Features from Home Screen

Android App Shortcuts — Launch Features from Home Screen App shortcuts provide quick access to specific features directly from the home screen. They improve user experience and engagement. Let's explore all three types. Static S…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!




Android App Shortcuts — Launch Features from Home Screen



App shortcuts provide quick access to specific features directly from the home screen. They improve user experience and engagement. Let's explore all three types.






Static Shortcuts



Define permanent shortcuts in your manifest:




<!-- res/xml/shortcuts.xml -->
<shortcuts xmlns:android="http://schemas.android.com/apk/res/android">
<shortcut
android:shortcutId="compose_message"
android:enabled="true"
android:icon="@drawable/ic_message"
android:shortcutShortLabel="@string/compose"
android:shortcutLongLabel="@string/compose_message">
<intent
android:action="android.intent.action.MAIN"
android:targetPackage="com.example.myapp"
android:targetClass="com.example.myapp.ComposeActivity" />
</shortcut>
</shortcuts>






Add to manifest:




<activity android:name=".MainActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<meta-data
android:name="android.app.shortcuts"
android:resource="@xml/shortcuts" />
</activity>






Receive intent extras:




class ComposeActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)

val recipientId = intent.getStringExtra("recipient_id")
val messageText = intent.getStringExtra("message_text")

// Handle shortcut intent
}
}









Dynamic Shortcuts



Create shortcuts at runtime with ShortcutManager:




val shortcutManager = getSystemService(ShortcutManager::class.java)

val shortcut = ShortcutInfo.Builder(this, "quick_reply")
.setShortLabel("Quick Reply")
.setLongLabel("Reply to recent messages")
.setIcon(Icon.createWithResource(this, R.drawable.ic_reply))
.setIntent(Intent(Intent.ACTION_VIEW).apply {
action = "com.example.myapp.QUICK_REPLY"
putExtra("mode", "quick")
})
.build()

shortcutManager.dynamicShortcuts = listOf(shortcut)






Important: Max 4 shortcuts total (static + dynamic).






Pinned Shortcuts



Allow users to pin shortcuts themselves:




val shortcutManager = getSystemService(ShortcutManager::class.java)

if (shortcutManager.isRequestPinShortcutSupported) {
val shortcut = ShortcutInfo.Builder(this, "settings")
.setShortLabel("Settings")
.setIcon(Icon.createWithResource(this, R.drawable.ic_settings))
.setIntent(Intent(Intent.ACTION_VIEW).apply {
action = "com.example.myapp.SETTINGS"
})
.build()

shortcutManager.requestPinShortcut(shortcut, null)
}









Best Practices





  • Icon sizes: Adaptive icons (108x108dp)


  • Label length: Short labels ≤20 chars, long labels ≤30 chars


  • Intent extras: Always include action to identify shortcut type


  • Target API 25+ for full shortcut support

  • Test on actual devices (shortcuts behave differently across launchers)



Static shortcuts provide always-available access, dynamic shortcuts adapt to usage patterns, and pinned shortcuts give users control. Combine them for optimal engagement.






Interested in mobile app development? Check out 8 Android app templates on Gumroad!

Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Android App Shortcuts — Launch Features from Home Screen

Thematisch verwandte Begriffe: Android, Shortcuts, Launch, Features · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-49449 | Joplin is an open source note-taking and to-do application that organise…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick