Skip to content

Add Quick Settings tile to launch Card Store from system UI#74

Merged
pawcoding merged 3 commits intostagingfrom
copilot/add-quick-settings-tile
Feb 20, 2026
Merged

Add Quick Settings tile to launch Card Store from system UI#74
pawcoding merged 3 commits intostagingfrom
copilot/add-quick-settings-tile

Conversation

Copy link
Contributor

Copilot AI commented Feb 19, 2026

This PR adds a Quick Settings entry point so users can open Card Store without navigating home/app drawer. Tapping the tile launches the main app activity directly from any foreground context.

  • Quick Settings Tile Service

    • Introduced AppLaunchTileService (TileService) to handle tile taps.
    • On tap, builds an explicit Intent to MainActivity with task/top flags for predictable resume/bring-to-front behavior.
    • Uses API-appropriate launch path:
      • Android 14+ via startActivityAndCollapse(PendingIntent)
      • Older versions via legacy startActivityAndCollapse(Intent)
  • Manifest Registration

    • Registered tile service in AndroidManifest.xml with:
      • android.permission.BIND_QUICK_SETTINGS_TILE
      • QS_TILE intent filter action
      • tile icon and label metadata
  • User-visible Label

    • Added quick_settings_tile_label string resource: “Open CardStore”
class AppLaunchTileService : TileService() {
  override fun onClick() {
    val launchIntent =
      Intent(this, MainActivity::class.java).apply {
        addFlags(Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TOP)
      }

    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE) {
      startActivityAndCollapse(
        PendingIntent.getActivity(
          this,
          0,
          launchIntent,
          PendingIntent.FLAG_IMMUTABLE or PendingIntent.FLAG_UPDATE_CURRENT,
        ),
      )
    } else {
      @Suppress("DEPRECATION") startActivityAndCollapse(launchIntent)
    }
  }
}
Original prompt

This section details on the original issue you should resolve

<issue_title>Add Quick Settings Tile to Launch App Anywhere</issue_title>
<issue_description>Add a Quick Settings tile that allows users to quickly launch the Card Store app from anywhere in the system. Tapping the tile should immediately start up the main activity, giving instant access to loyalty cards regardless of what app the user is currently using. This improves accessibility and ease-of-use for frequent users.</issue_description>

Comments on the Issue (you are @copilot in this section)


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Co-authored-by: pawcoding <78467484+pawcoding@users.noreply.github.com>
Copilot AI changed the title [WIP] Add Quick Settings tile to launch Card Store app Add Quick Settings tile to launch Card Store from system UI Feb 19, 2026
Copilot AI requested a review from pawcoding February 19, 2026 19:51
@pawcoding pawcoding marked this pull request as ready for review February 20, 2026 18:39
Copilot AI review requested due to automatic review settings February 20, 2026 18:39
@pawcoding pawcoding merged commit c426d90 into staging Feb 20, 2026
3 checks passed
@pawcoding pawcoding deleted the copilot/add-quick-settings-tile branch February 20, 2026 18:42
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a Quick Settings tile feature that allows users to quickly launch the Card Store app from the Android system Quick Settings panel. The implementation provides instant access to loyalty cards from anywhere in the system, improving user convenience and accessibility.

Changes:

  • Introduced AppLaunchTileService that handles tile clicks and launches MainActivity with appropriate API-level handling
  • Registered the tile service in AndroidManifest.xml with proper permissions and metadata
  • Added localized string resources for the tile label in English and German
  • Modified MainActivity launch mode to singleTask for proper task management when launched from multiple entry points

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
app/src/main/java/de/pawcode/cardstore/AppLaunchTileService.kt New TileService implementation with API-level specific activity launching
app/src/main/AndroidManifest.xml Service registration with permissions, MainActivity launchMode configuration
app/src/main/res/values/strings.xml English label for Quick Settings tile
app/src/main/res/values-de/strings.xml German translation for Quick Settings tile label


val launchIntent =
Intent(this, MainActivity::class.java).apply {
addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
Copy link

Copilot AI Feb 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description claims this code uses FLAG_ACTIVITY_CLEAR_TOP but the actual implementation only uses FLAG_ACTIVITY_NEW_TASK. Since MainActivity is configured with launchMode="singleTask" in the manifest, the current approach will work correctly - singleTask mode automatically clears activities above it in the task. However, the PR description should be updated to match the actual implementation, or if FLAG_ACTIVITY_CLEAR_TOP was intentionally omitted, this should be documented.

Copilot uses AI. Check for mistakes.
pawcode-development-releaser bot pushed a commit that referenced this pull request Feb 20, 2026
# [1.5.0-staging.1](v1.4.3...v1.5.0-staging.1) (2026-02-20)

### Features

* **quick-settings:** add tile to launch app ([#74](#74)) ([c426d90](c426d90))
@pawcoding pawcoding mentioned this pull request Feb 20, 2026
@pawcode-development-releaser
Copy link

🎉 This PR is included in version 1.5.0-staging.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

pawcode-development-releaser bot pushed a commit that referenced this pull request Feb 26, 2026
# [1.5.0](v1.4.3...v1.5.0) (2026-02-26)

### Bug Fixes

* **biometric:** do not call onError on transient authentication failures ([4ea1765](4ea1765))

### Features

* **shortcut:** add dynamic shortcuts ([8cb18c3](8cb18c3))
* **shortcut:** add shortcut option to card options ([38a5104](38a5104))
* **quick-settings:** add tile to launch app ([#74](#74)) ([c426d90](c426d90))
@pawcode-development-releaser
Copy link

🎉 This PR is included in version 1.5.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants