Load complete reply threads and make keyboard dismissal reliable - #228
Open
Xare123 wants to merge 3 commits into
Open
Load complete reply threads and make keyboard dismissal reliable#228Xare123 wants to merge 3 commits into
Xare123 wants to merge 3 commits into
Conversation
This was referenced Jul 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part 3 of 3. This replaces #225, which mixed too many unrelated themes to review. Split into focused PRs so each can be evaluated on its own.
Series: Part 1 - delivery integrity - Part 2 - lifecycle leaks - Part 3 - reply threads and keyboard
What this fixes
Reply threads opened without their originating message. Tapping a threaded reply built the thread view from the currently loaded 50-message window and omitted the message being replied to, so a reply appeared with no context. On iOS the equivalent view always shows the originator first. The thread now loads the complete locally stored chain including the originator, in chronological order, and keeps group sender names so you can tell who said what.
Long chains render lazily rather than building every bubble up front, and multi-digit reply part indexes are parsed correctly instead of truncating at the first digit.
The keyboard was hard to dismiss. Inside a conversation the only way to lower the keyboard was the Android Back button, and pressing it twice left the chat entirely. Tapping the transcript and swiping down now both dismiss it, while Back keeps its existing two-step behavior. A keyboard-visibility subscription that was never cancelled is now cancelled on dispose.
Reply navigation could race the widget lifecycle. Navigating to a replied-to message could run against a controller whose widget had already been torn down. The navigation path now checks lifecycle state before acting, and the reaction widget no longer holds a controller past its widget's life.
Validation
flutter analyze: no errors in any file this PR touches. The analyzer reports 31 pre-existing errors inlib/database/html/, vendoredrust_builder/cargokit/, and thetelephony_plusexample; all are unchanged by this PR and present on the base branch.Notes for review
rustpushsubmodule pointer.chat_messages.dart,database/io/message.dart,messages_service.dart, and thechat_messagestest) and three with Part 2 (conversation_view.dart,message_holder.dart,conversation_view_controller.dart), but edits different regions of each. Whichever merges first, I will rebase the others.