Add link management: create, select, delete with undo/redo
Implement full link workflow between component slots on the wiresheet: - Link Mark / Link From / Link To context menu items for creating links - Link dialog with slot type validation and source/target swap button - Selectable link wires (click to highlight in red) with right-click delete - Undo/redo support for both add and delete link operations - Component deletion already cascades to remove related links Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -36,6 +36,9 @@ current_file_path = None
|
||||
active_components_list = [] # Tracks what components are actively painted
|
||||
selected_canvas_tag = None # Tracks the currently clicked/highlighted canvas component tag
|
||||
selected_tree_item_id = None # Tracks the currently right-clicked Treeview item
|
||||
link_mark_element = None # Component marked as a link endpoint via "Link Mark"
|
||||
selected_link_tag = None # Canvas tag of the currently selected (red-highlighted) link wire
|
||||
canvas_link_map = {} # Canvas link tag -> ET.Element (<link>)
|
||||
xml_root_element = None # Keep a persistent root reference to redraw tree layouts cleanly
|
||||
current_sheet_parent = None # Element whose children are painted; None means the app root
|
||||
|
||||
|
||||
Reference in New Issue
Block a user