Skip to content

Preserve POI type search text until attribute editor closes#953

Open
tordans wants to merge 1 commit into
bryceco:masterfrom
tordans:cursor/preserve-feature-search-until-dismiss-6778
Open

Preserve POI type search text until attribute editor closes#953
tordans wants to merge 1 commit into
bryceco:masterfrom
tordans:cursor/preserve-feature-search-until-dismiss-6778

Conversation

@tordans
Copy link
Copy Markdown
Contributor

@tordans tordans commented May 30, 2026

Summary

When choosing a feature type from search, returning to the tags screen after a mistaken pick previously left the type picker with an empty search field. The search query is now kept for the whole time the POI attribute editor (tab bar modal) stays open, and is cleared only when that modal is dismissed (save, cancel, interactive dismiss, etc.).

Implementation by Cursor

  • POIFeaturePickerViewController: store the current search string in a private static while the user edits; restore it in viewWillAppear and reuse a single refreshSearchResults helper from searchBar(_:textDidChange:).
  • POITabBarController: clear the stored string in viewWillDisappear when the controller is being dismissed or removed from its parent.

The system search field clear control still clears the text through the existing delegate path.

Testing by me

Manually tested with Xcode Simulator:

gomap-search.min.mov

Keep the feature picker search query in memory while the POI tab bar
modal is open so returning from a mistaken selection does not clear it.
Clear the stored query when the modal is dismissed (save, cancel, swipe,
or equivalent). The search field clear control still resets the query
via the existing text-change path.

Co-Authored-By: Tobias <t@tobiasjordans.de>
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.

2 participants