← Commit history

Document the taskbar thumbnail preview surfaces, why the thumb toolbar is blocked for Chrome-owned windows, and the duplicate-session-tag caption fix

John Lauer ·2f3b067618 ·3mo ago ·parent e43a4e7
1 file changed +37
dev-skills/pup-bridge-debug/SKILL.md+37
@@ -478,3 +478,40 @@ Verified 2026-07-21: hdr-wiki→pup-cat-wiki9.ico, hdr-web→pup-cat-web9.ico, h   interface (`__ComObject does not contain a method named 'GetValue'`, and `[IPropertyStore]$x`   throws). Compile a tiny C# reader with `Framework64\v4.0.30319\csc.exe` and run the exe instead —   the interop binds correctly there. (PropRead.cs pattern in the repo history.)++## The taskbar THUMBNAIL PREVIEW as a status surface (what Windows actually allows)++The hover-preview popup has five surfaces. Only two are reachable from a bridge today:++| Surface | API | Reachable? |+|---|---|---|+| Caption (title line) | it IS the window title | YES today (we inject "○ Public · …") |+| Thumbnail tooltip | `ITaskbarList3::SetThumbnailTooltip` | needs an AD verb (easy: hwnd + string, no callback) |+| Thumbnail clip | `ITaskbarList3::SetThumbnailClip` | needs an AD verb (easy: hwnd + RECT) |+| Thumbnail toolbar (≤7 buttons) | `ThumbBarAddButtons` | **BLOCKED for pup** — see below |+| Custom iconic thumbnail | `DwmSetIconicThumbnail` + `DWMWA_FORCE_ICONIC_REPRESENTATION` | possible, but REPLACES the live preview |++**Why the thumbnail toolbar is blocked for us:** the shell delivers thumbbar button clicks as+`WM_COMMAND` **to the window that owns the thumbnail**. Pup windows are `Chrome_WidgetWin_1` — owned+by Chrome, not by AD. Receiving those clicks would require subclassing a third-party process's window+proc (DLL injection). That is why Chrome can put media buttons on its own thumbnails and we cannot.+Do not re-litigate this without a clean cross-process route.++**Caption budget:** the caption truncates at ~25-30 chars, so only the FIRST tokens survive+("○ Public · Hydrogen De…"). Keep the state glyph + word at the front, and put everything else+(pup/Chrome/tab-count) in the thumbnail TOOLTIP once that verb exists — the tooltip is the only+uncapped text surface on the popup.++**Also already available and unused:** `desktop_taskbar {progress:{state,value}}` paints a+green/yellow/red progress bar on the button (ITaskbarList3 progress). No AD work needed.++### Duplicate session tags bloat the caption (fixed v1.9.56)++Measured live: `"○ Public · Hydrogen Desktop - Adom Wiki (session: hdr-wiki) (session: hdr-wiki)"`+(107 chars). TWO MutationObservers touch this title — the session-suffix injector and the wiki+state-glyph injector — and a page that rewrites its own title can let both fire before either sees the+other's write, so each appends. The old injector only asked "is my marker absent?", so a second copy+was never collapsed. Fixed: the injector now COUNTS its own tag and normalises to exactly one+(`n===1` leave, `n===0` append, `n>1` strip-all-then-append). It only matches its OWN sid so it never+fights `retagSessionTitle` on an adopted tab. Duplicated tags also risk AD's title-based window+resolution landing on the wrong window — the exact class of bug behind earlier mis-branding.