Added: Text Input View History feature with up/down swipe navigation #4679
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.
Description
Adds command history functionality to the terminal toolbar's text input view, accessible via up/down swipe gestures.
Motivation
When using Termux with tmux sessions (especially over SSH), vertical swipes in the terminal scroll within tmux - a very
useful feature. However, if text is submitted from the text input view while tmux is in scroll/copy mode, the command is
lost as tmux doesn't receive it.
This feature allows users to:
Implementation
This provides a safety net for the common workflow of using Termux with tmux/SSH sessions where scroll mode can
interfere with command submission.
Disclaimer
This is my first time working with the Termux codebase so I'm not sure if the architecture fits cleanly or if there's other aspects I should have reused rather than reimplement etc.
The change submitted here has been written with the assistance of Claude Code (AI) with code review and testing by me, however I don't code in Java regularly so certainly might have missed things.
I'm very open to feedback and making further changes if requested!