Flow: right-click menus like SaraFem's

Boxes, arrow labels and the background each get a menu (edit, delete,
connect, test a file, copy path/patterns, ...), using SaraFem's single
shared ContextMenu opened from _RequestMenu. Tools can open on the tester
for a given input.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
sarahandClaude Opus 5.5 committed 2026-10-08 18:28:02 +02:00
1 parent d0e5eb2086
commit 4c0a8e4d4f
3 files changed
+193 -18

No files matched your search

+7 -1
View File
@@ -65,7 +65,11 @@ class ToolsPage(ft.Column):
self.Body,
]
def Refresh(self) -> None:
def Refresh(self, Section: str = "", TestInput: str = "") -> None:
"""Section and TestInput open a given tool, e.g. the tester for an input
right-clicked in Flow."""
if Section in self.Buttons:
self.Section = Section
self.TheSetup, Error = self.App.LoadSetup()
if self.TheSetup is None:
self.Body.content = EmptyState("Can't read SaraSortd's config.", Error)
@@ -76,6 +80,8 @@ class ToolsPage(ft.Column):
Current = Picker.value
Picker.options = [ft.DropdownOption(key=PathText, text=DisplayPath(PathText)) for PathText in Inputs]
Picker.value = Current if Current in Inputs else (Inputs[0] if Inputs else None)
if TestInput in Inputs:
self.TestInput.value = TestInput
self._Show(self.Section)
def _Show(self, Name: str) -> None: