Unify result context menus between grid and list layouts#905
Merged
multiplex55 merged 1 commit intomasterfrom Feb 22, 2026
Merged
Conversation
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.
Motivation
cols/col_width/ui.end_row) while keeping refresh/focus side effects intact.Description
ResultContextMenuKindenum to classify actionable result kinds (folder, bookmark, timer, stopwatch, snippet, tempfile, note, clipboard, todo, default).result_context_menu_kind(&self, action: &Action) -> ResultContextMenuKindto deterministically mapActionentries to menu kinds.attach_result_context_menu(&mut self, action: &Action, menu_resp: egui::Response, refresh: &mut bool, set_focus: &mut bool) -> egui::Responsethat builds the full context menu UI and preserves all branch-specific behaviors (folders, bookmarks, notes/todos, snippets, timers/stopwatches, clipboard entries, Edit App, pin/unpin) and mutatesrefresh/set_focuswhen appropriate.Responseis passed throughattach_result_context_menubefore click handling; list rendering also now uses the same helper (menu geometry and left-click activation unchanged).grid_context_menu_eligibility_uses_result_actions,context_menu_parity_bookmark_between_list_and_grid, andcontext_menu_parity_todo_between_list_and_grid.Testing
cargo fmtto format the code and succeeded.result_context_menu_kind) and assert parity between list and grid classifications.cargo test grid_context_menu -- --nocapture), but the build failed due to a missing system dependency for a transitive crate: the systemalsapkg-config file (alsa.pc) is not available in this environment, causing the test run to error before tests could execute.Codex Task