Repository navigation
Extend edit controls to Bdv/Bvv - #334
Merged
Merged
Conversation
This is major refactoring: the node-editing logic of the ImagePlus tracing canvas now lives in a viewer-agnostic class, so the same actions of the ImagePlus contextual menu are available in Bdv & Bvv (context menu, single-key shortcuts, hover-based active node, undo, etc.). New classes - PathNodeEditor: Operations on a single Path (delete, insert, move, lock, radius, tag, re-root, split, connect, undo). Returns a Result that front-ends route with Result#dispatch(). Shared helpers: deleteNodeOrPath(gui), tagNode(path, index, color), replaceTree(), structuralChange() - NodeEditCommand / ContextMenuCommand: Host labels, icons, default shortcuts and menu population, shared by the canvas and the viewers - BigViewerEditor / BigViewerMenu: Bdv/Bvv interaction layer (hover picking, key bindings, right-click menu) on top of PathNodeEditor SNT / SNTUI changes: - SNT holds the PathNodeEditor (editing path, active node, undo history) shared by canvas, Bdv and Bvv; adds enterEditMode(Path), exitEditMode(), getEditModeBlocker(), notifyActiveNodeChanged() and notifyEditingPathChanged() (throttled) - enterEditMode(Path) selects the path first, as all edit operations require the editing path to be selected - editModeAllowed() no longer swaps the editing path while already editing; Stream mode restores its tracing state on exit - SNTUI fans Edit Mode notifications out to open viewers only (getOpenBigViewers() skips disposed ones) and tracks the most recently activated viewer Fixes / Behavior changes: - Bvv AnnRenderer: screen data and layer ranges are published as one immutable Frame/Source pair, fixing the unsynchronized screenData race (NPE in tests) - Bvv#getClickedPosition(null) no longer returns a stale cached position - SNT#startSholl() converts calibrated coordinates to pixel indices - Sholl at nearest node in viewers: selected paths, else the rendered path nearest to the cursor (same lookup as Grab Nearest Path) - Bookmarks added from a viewer in classic mode use the viewer's current timepoint; BookmarkManager moves open viewers and image windows, and reports locations outside the (materialized crop of the) image - Radius prompt: tolerate a corrupted saved value, message says "non-negative" (0 is accepted) - Deleting a whole path from the canvas now leaves Edit Mode; refusing to delete a junction node opens a dialog - Right-clicks no longer trigger tracing clicks in the viewers; M adds a bookmark in classic mode (it was blocked) - Removed the "Continue Extending Path" toolbar toggle from Bvv/Bdv (the action remains in the context menu) - Misc fixes
…/Bvv ... while at it: - improve min-max detection - Fix NPE - Improve nearest point detection - Fix selection in Bdv
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.
This is major refactoring: the node-editing logic of the ImagePlus tracing canvas now lives in a viewer-agnostic class, so the same actions of the ImagePlus contextual menu are available in Bdv & Bvv (context menu, single-key shortcuts, hover-based active node, undo, etc.).
New classes
SNT / SNTUI changes:
Fixes / Behavior changes: