diff options
| author | Danilo M. <danix@danix.xyz> | 2026-10-22 11:19:32 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-10-22 11:19:32 +0200 |
| commit | 44d4a132c193907ee53de180ad28e697828009e3 (patch) | |
| tree | 001b9088b55dfd7d4ab73a1687bce1abe3da6e47 /app/src/main/java/mygram/droid/FolderActivity.java | |
| parent | bf319064f127e3cf97a46d2c172bdacdc8f8a783 (diff) | |
| download | mygram-droid-44d4a132c193907ee53de180ad28e697828009e3.tar.gz mygram-droid-44d4a132c193907ee53de180ad28e697828009e3.zip | |
Fix lifecycle, focus loss, crossfade and tab race review findings
- MainActivity: remove rotate callbacks in onDestroy, ignore connect
results once destroyed, rotate the background only while resumed,
guard the fade end action.
- HomeRows: each row owns one TileAdapter over a mutable list; rebinds
refill it and notifyDataSetChanged instead of setAdapter, so focus and
scroll survive a sample arriving (change payload keeps the holder).
- Crossfade: flip front only on onResourceReady, cancel the animation
before resetting alpha.
- Tab loads ignore errors from a tab that is no longer shown; Home does
not fire a second /folders request while one is in flight.
- Load the instance logo after login in connect().
- FolderActivity: request grid focus after layout.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'app/src/main/java/mygram/droid/FolderActivity.java')
| -rw-r--r-- | app/src/main/java/mygram/droid/FolderActivity.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/src/main/java/mygram/droid/FolderActivity.java b/app/src/main/java/mygram/droid/FolderActivity.java index 8da2533..10a9940 100644 --- a/app/src/main/java/mygram/droid/FolderActivity.java +++ b/app/src/main/java/mygram/droid/FolderActivity.java @@ -53,7 +53,7 @@ public final class FolderActivity extends Activity { Collections.shuffle(posts); grid = Ui.grid(this, Ui.postTiles(this, posts), Ui.POST_W, Ui.POST_H, 6); show(grid); - grid.requestFocus(); + grid.post(grid::requestFocus); // after layout }, e -> show(Ui.text(this, "Cannot load folder: " + e.getMessage(), 18))); } |
