summaryrefslogtreecommitdiff
path: root/android/app/src/main/res/drawable
diff options
context:
space:
mode:
authorPeter Stone <thepeterstone@gmail.com>2026-08-06 17:32:08 +0000
committerPeter Stone <thepeterstone@gmail.com>2026-08-06 17:32:08 +0000
commitf7d18eae924a221f12293c3063e46b791468623f (patch)
tree339ee35ec04411ecda79f020429a75268d4e8859 /android/app/src/main/res/drawable
parenta1ca48e0dc760393a59fe745736b6b0668fade17 (diff)
Widget: real launcher icon, fix double title bar, rename app to "doot"
Icon: adaptive-icon vector launcher icon reusing web/static/favicon.svg's brand mark (indigo->purple gradient square, white checkmark) so the app and web dashboard visually match. minSdk 36 (per build.gradle.kts) means mipmap-anydpi-v26 alone is sufficient, no legacy PNG fallback needed. Double title bar: DashboardActivity inherited the app-wide Theme.DeviceDefault.DayNight, which has a native ActionBar, stacked on top of the new Compose TopAppBar from the last commit -- visibly two bars, showing "Doot" (static ActionBar label) above "Personal Dashboard" (the Compose bar tracking the web page's own <title>). Added Theme.Dashboard (NoActionBar) for the activity, and stopped tracking the WebView's document.title for the Compose bar's title text -- the dashboard is a single HTMX-swapped page (see DashboardActivity's class doc), so the title never meaningfully changes, and it was just producing a second, differently-branded piece of text. Renamed the app from "Doot Widget" to "doot" throughout (application label, widget-picker description, Settings screen heading) to match the project's actual branding. Also: the web Settings page's "Back to Dashboard" link was a plain <a href="/">, which in the WebView pushes a NEW history entry for "/" instead of reusing the one already on the stack -- so Settings <-> Home round trips kept growing the WebView back-stack ("zigzag"), and the in-app back arrow/hardware back key never actually unwound it. Now it calls history.back() when there's stack to pop, falling back to a plain navigation only if there isn't (e.g. Settings opened directly). Verified on emulator-5556: rebuilt and reinstalled, confirmed a single title bar (no native ActionBar behind the Compose one), confirmed the launcher icon renders (checked via Settings > App info, since this AVD's launcher doesn't expose an app drawer over adb), no crashes. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EZ7ikw2ukGJFTHE3bJS7zL
Diffstat (limited to 'android/app/src/main/res/drawable')
-rw-r--r--android/app/src/main/res/drawable/ic_launcher_background.xml21
-rw-r--r--android/app/src/main/res/drawable/ic_launcher_foreground.xml18
2 files changed, 39 insertions, 0 deletions
diff --git a/android/app/src/main/res/drawable/ic_launcher_background.xml b/android/app/src/main/res/drawable/ic_launcher_background.xml
new file mode 100644
index 0000000..5642471
--- /dev/null
+++ b/android/app/src/main/res/drawable/ic_launcher_background.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Same indigo->purple gradient as web/static/favicon.svg -->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:aapt="http://schemas.android.com/aapt"
+ android:width="108dp"
+ android:height="108dp"
+ android:viewportWidth="108"
+ android:viewportHeight="108">
+ <path android:pathData="M0,0h108v108h-108z">
+ <aapt:attr name="android:fillColor">
+ <gradient
+ android:type="linear"
+ android:startX="0"
+ android:startY="0"
+ android:endX="108"
+ android:endY="108"
+ android:startColor="#6366f1"
+ android:endColor="#a855f7" />
+ </aapt:attr>
+ </path>
+</vector>
diff --git a/android/app/src/main/res/drawable/ic_launcher_foreground.xml b/android/app/src/main/res/drawable/ic_launcher_foreground.xml
new file mode 100644
index 0000000..25c2105
--- /dev/null
+++ b/android/app/src/main/res/drawable/ic_launcher_foreground.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- The favicon.svg checkmark (M30,50 L45,65 L70,35 in a 100x100 viewport),
+ scaled 1:1.08 into this 108x108 adaptive-icon foreground layer. Already
+ sits well inside the safe zone (inner 72dp) since the source path's
+ bounding box only spans the middle 40% of its viewport. -->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ android:width="108dp"
+ android:height="108dp"
+ android:viewportWidth="108"
+ android:viewportHeight="108">
+ <path
+ android:pathData="M32.4,54 L48.6,70.2 L75.6,37.8"
+ android:strokeColor="#FFFFFF"
+ android:strokeWidth="10.8"
+ android:strokeLineCap="round"
+ android:strokeLineJoin="round"
+ android:fillColor="#00000000" />
+</vector>