Auto-select timestamp text in TTD navigation dialog #879
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.
Problem
When the "Navigate to TTD Timestamp" dialog opens, the current timestamp is displayed in the input field but not selected. This requires users to manually select the text before they can:
This creates unnecessary friction in a common workflow when working with Time Travel Debugging (TTD).
Solution
Added a call to
selectAll()
on the timestamp QLineEdit field after populating it with the current TTD position. This automatically selects/highlights the text when the dialog opens.Changes
Modified:
ui/timestampnavigationdialog.cpp
In the
initializePositions()
method, after setting the text:User Experience Improvement
Before:
After:
This follows standard UI patterns where pre-populated dialog fields have their content selected by default, making them immediately ready for user action.
Testing
The change follows Qt's standard QLineEdit API and patterns used throughout Qt applications. No additional testing infrastructure is required for this UI enhancement.
Fixes the issue reported in #[issue_number] where @xusheng6 requested this functionality improvement.
Original prompt
Fixes #870
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.