Skip to content

ADFA-4785: Send the app — bootstrap K2Go onto a phone without it#233

Merged
luisguzman-adfa merged 13 commits into
mainfrom
feat/ADFA-4785-send-the-app
Jul 21, 2026
Merged

ADFA-4785: Send the app — bootstrap K2Go onto a phone without it#233
luisguzman-adfa merged 13 commits into
mainfrom
feat/ADFA-4785-send-the-app

Conversation

@luisguzman-adfa

Copy link
Copy Markdown
Collaborator

Secondary 'Send the app first' entry on the Clone Send screen opens a sub-view that serves this app's APK over HTTP (reuses ApkServer) as a QR, with an Android share-sheet fallback (FileProvider) and a 'Next: copy the library' hand-off back to the normal rsync flow. The main Send flow is unchanged and stays the default.

Per the mockup. Reuses ApkServer / ApkShareName. Needs a local build to verify.

Secondary 'Send the app first' entry on the Clone Send screen opens a
sub-view that serves this app's APK over HTTP (reuses ApkServer) as a QR,
with an Android share-sheet fallback (FileProvider) and a 'Next: copy the
library' hand-off back to the normal rsync flow. The main Send flow is
unchanged and stays the default.

Per the mockup. Reuses ApkServer / ApkShareName. Needs a local build to verify.
…he-app

# Conflicts:
#	controller/app/src/main/java/org/iiab/controller/redesign/CloneFragment.java
@luisguzman-adfa
luisguzman-adfa marked this pull request as draft July 21, 2026 04:02
Replace the persistent top Send/Receive toggle with a first-screen intent
fork: 'What do you want to do?' -> Send to another phone / Receive from
another phone. Picking one enters that side; a '<- Back' header returns to
the fork. Reuses the existing Side SEND/RECEIVE state and per-side rendering;
the old toggle row is kept in the layout but hidden. No transport change.
…ring

Reframe the Send badges as a 3-step spine over the existing pieces:
- Connect (1) = the join stage; Get app (2) = the 'Send the app' sub-view;
  Copy (3) = the transfer/START stage. Steps never renumber.
- Connect: 'Send the app first' card -> step 2; 'They already have K2Go ›'
  (advance) skips to Copy. Get app 'Next: copy the library' -> step 3 (done),
  'Back' -> Connect. Copy 'Back to step 1' -> Connect.
- Badge 2 shows filled/done when Get app was completed, neutral when skipped.

Reuses renderSendApp / renderStartState; no transport change. (Explicit
'omitido' label on the skipped badge + the Wi-Fi Connect step are follow-ups.)
- Step title under the spine: 'Step 1 · Connect the other phone' (and
  'Step 3 · Copy the library' on the copy step).
- 'Next: get the app' is the primary button (advance) -> step 2.
- 'Skip — they already have K2Go' as a small link at the bottom -> step 3.
- Remove the 'Send the app first' card from the flow (it broke the sequence);
  Get app is now reached via the primary button.
Step 2 now shows the shared spine + 'Step 2 · Get the app' title like steps 1
and 3, instead of its own 'Send the app' header. Dropped the redundant
sub-view title/subtitle; back relabeled to '< Back' (-> Connect); primary
button 'Installed? Copy the library' (-> Copy). Step 3 already carries its
'Step 3 · Copy the library' title.
…name Connect->Join

- Both Hotspot and Wi-Fi now start at step 1 (Join); setMode no longer sends
  Wi-Fi straight to Copy.
- 'Next: get the app' advances to step 2 in BOTH modes (removed the
  hotspot-only guard on advance); step 3 (Copy) is reached only via 'Installed?
  Copy the library' or 'Skip - they already have K2Go'.
- Wi-Fi now has a real step 1 (Join): instructions + Next + skip (no QR; the
  sender can't mint a Wi-Fi QR — open-settings helper is a follow-up).
- Renamed the step 'Connect' -> 'Join' (badge + title) to avoid confusion with
  the Connect tab. Spine active step is now mode-agnostic.
…-1 skip prominent

- Wi-Fi step 1 (Join) gains a secondary 'Share Wi-Fi via Android settings'
  button (opens Settings so the host can share the network QR); primary stays
  'Next: get the app'.
- The 'Skip - they already have K2Go' link is now bold, right-aligned and sits
  directly under the 'Next: get the app' button (was a small centered note), so
  it reads as a real alternative that jumps step 1 -> step 3.
… step 1)

setMode reset stage to JOIN, so toggling Hotspot<->Wi-Fi threw the user back to
step 1 even from Copy. Decouple mode from step: setMode only changes the network
and re-renders the current step; entering Send (setSide) is what starts at step 1.
Switching network at Copy now just refreshes the QR with the new IP.
…rimary 'Next'

Give the share action its own button placed above 'Next: get the app' (it's the
immediate thing to do on arriving at the Wi-Fi tab), instead of reusing the Stop
button below. Secondary style; 'Next' stays the primary, and the bold skip jumps
straight to Copy.
Step 2 kept using the hotspot IP regardless of the selected network. Show the
Hotspot/Wi-Fi selector on step 2 too, and build the APK download QR from the IP
of the chosen mode (hotspot vs Wi-Fi); switching the selector refreshes the QR.
Switching Hotspot<->Wi-Fi while sharing at step 3 drops the active connection
and cuts any copy in progress. Route the tab taps through requestMode(): if a
share is active at Copy, ask 'Switch to Hotspot/Wi-Fi?' ('This stops any copy in
progress. The other phone can start again by rescanning the new code.') with
Cancel / Switch; otherwise switch directly. Also reword the Stop dialog to
'This stops any copy in progress.'
@luisguzman-adfa
luisguzman-adfa marked this pull request as ready for review July 21, 2026 22:05
@luisguzman-adfa
luisguzman-adfa merged commit ffe374d into main Jul 21, 2026
1 check passed
@luisguzman-adfa
luisguzman-adfa deleted the feat/ADFA-4785-send-the-app branch July 21, 2026 22:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant