chore(phase-1/m4.5c): delete spike modules; record M4.4/M4.5 findings

6.6 executed: :spike:data-jvm and :spike:compose-jvm leave the build
now that :desktopApp hosts the real screens (M4.5b) — everything they
proved has a permanent home in :core:data-jvm, :composeApp (jvm) and
:desktopApp; their findings already live in the feasibility log.

tools/DESKTOP_FEASIBILITY.md gains the M4.4a-e + M4.5a-c entries:
seam inventory (image decode, editor intake, voice slot, platform
back, shared settings sections, JVM EXIF), the hide-not-fake §6.5
rulings applied, the harness note about cold-build run timeouts,
the M4.4/M4.5 verification suite, and the M5 next-up.

Verified post-deletion: assembleDebug :desktopApp:build SUCCESSFUL
+ run --self-test --settings-smoke --editor-smoke (SELFTEST id=1,
SETTINGS shown, EDITOR shown, ST_EXIT=0) + :core:data-jvm:smoke
(M1a PASS) + orientationSmoke (M4.4e PASS).
This commit is contained in:
Incido Developer committed 2026-10-06 19:55:26 +13:00
1 parent cce35587fc
commit faab0cde98
19 files changed
+77 -1575

No files matched your search

+72
View File
@@ -730,6 +730,78 @@ each screen moves once its own android.* seam is solved. M4.5 then
hosts the real screens in `:desktopApp` (replacing Main.kt's
stand-in) and deletes `spike/` (§6.6).
**M4.4 — the screens: DONE.** Each screen moved once its own seam was
solved; every seam landed as expect/actual with the Android code kept
verbatim in `androidMain` (the §6.3 discipline, one seam per commit):
- **M4.4a** — first screens (list + drawer) to commonMain.
- **M4.4b** — `ImageDecode.kt` (`decodeImageBytes`: skia
`Image.makeFromEncoded` on both targets — the BitmapFactory replacement);
`ImageViewerScreen` + card thumbnails moved. `ioDispatcher` seam.
- **M4.4c** — `NoteEditorScreen` (the big one) to commonMain behind the
**EditorIntake** seam (`rememberEditorIntake`): the Android actual is
the verbatim launcher code (camera + permission chain, SAF picker,
RECORD_AUDIO dance, FileProvider/ACTION_VIEW open, Toasts); the JVM
actual answers with AWT FileDialog + `Desktop.open` and reports
`supportsCamera/supportsVoice = false`, so the editor HIDES those
buttons (§6.5 — hidden, not stubbed). `VoiceNoteSlot` (Android renders
the untouched recorder; JVM renders nothing). `PlatformBackHandler`
(activity-compose on Android; no-op on desktop — Esc routing is M5).
The editor's `securityManager` param became a neutral
`beginExternalActivity: (() -> Unit)?`.
- **M4.4d** — the platform-neutral settings sections (Appearance /
Backup / About + `SettingsSection/Toggle/Row`) to commonMain. Design
call recorded: full commonization of the 1026-LOC SettingsScreen buys
nothing — SecuritySection is BiometricPrompt + PIN state machines;
each platform keeps its plumbing, both share the UI vocabulary. Two
callbacks went nullable to HIDE platform-incapable rows (dynamic color,
Carnet importer). Made PUBLIC in M4.5a (desktopApp is a separate module).
- **M4.4e** — the §6.3 EXIF row's "verify a JVM decoder exists" gate:
metadata-extractor 2.19.0 (first Maven Central pull of the phase) +
`JvmImageOrientationNormalizer` (BufferedImage rotate, ImageIO JPEG
@0.92) — same store-time bake contract as Android. `:core:data-jvm:orientationSmoke`
hand-splices an APP1 Orientation=6 JPEG and asserts pixels rotate
(4x2→2x4), passthroughs hold, output is flag-free. `RESULT: M4.4e PASS`.
**M4.5 — real screens hosted; spike deleted: DONE.**
- **M4.5a** — `DesktopSettingsScreen` composes the M4.4d sections +
desktop Encryption rows. The M2/M3 flows were SPLIT, not copied:
`BackupFlows`/`SecurityKeyFlows`/`toggleDesktopEncryption` own pick +
bridge + dialogs; the settings buttons drive the exact M2-proved code.
`--settings-smoke` composes it headlessly.
- **M4.5b** — `DesktopShell`: **the app's own NoteListScreen,
IncidoDrawer and NoteEditorScreen run on the desktop** over
`LocalAppGraph provides DesktopContainer`, themed by the shared
`IncidoTheme`. App.kt's NavHost reduces to three pieces of state. The
`--editor-smoke` leg closed the last M4 unknown: JetBrains lifecycle's
fallback ViewModelStoreOwner means `viewModel(factory=…)` just works
on the JVM. The M1b stand-in UI and the M2/M3 menu skins are deleted.
- **§6.6** — `spike/data-jvm` + `spike/compose-jvm` removed from the
build (their findings all have permanent homes now).
Harness note for the smoke legs: the FIRST `:desktopApp:run` after a code
change sometimes rides out the `timeout` because the same invocation
rebuilds the jar first; warm re-runs auto-exit 0. Not a teardown wedge —
the app prints its legs and exits in ~20 s.
```
M4.4/M4.5 suite (per commit; final run this entry):
./gradlew assembleDebug :desktopApp:build BUILD SUCCESSFUL
:composeApp:compileKotlinJvm + compileDebugKotlinAndroid SUCCESSFUL
:desktopApp:run … --self-test SELFTEST id=1 → RENDER, exit 0
:desktopApp:run … --settings-smoke SETTINGS shown, exit 0
:desktopApp:run … --editor-smoke EDITOR shown, exit 0
:core:data-jvm:smoke RESULT: M1a PASS
:core:data-jvm:orientationSmoke RESULT: M4.4e PASS (5/5)
objectbox-models clean
```
**Next up: M5** — desktop polish: Esc/back routing through
`PlatformBackHandler` (editor discard prompt), keyboard shortcuts,
window/menu integration, packaging (`createDistributable` re-verify +
the M4.3d artifact notes), and the §9 perf pass on the real screens.