Skip to content

Commit

Permalink
Update classdesc ref, allowing polymorphic reference returns to be ac…
Browse files Browse the repository at this point in the history
…cessible in python.
  • Loading branch information
highperformancecoder committed Dec 13, 2024
1 parent aaaf0f8 commit 1bedb12
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 11 deletions.
2 changes: 1 addition & 1 deletion ecolab
Submodule ecolab updated 1 files
+1 −1 classdesc
1 change: 0 additions & 1 deletion test/00/godleyResize.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ minsky.canvas.mouseUp(300, 200) # Finalize the position
# Attempt to select the GodleyIcon
godley_icon = findObject("GodleyIcon")
#godley_icon=minsky.canvas.itemFocus() # minsky.canvas.itemFocus() does not work
assert godley_icon is not None, "GodleyIcon not found or not focused"
# Print details about the focused item
Expand Down
9 changes: 1 addition & 8 deletions test/00/inputWired.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,7 @@ assert integrationOp is not None, "Integration operation not found or not focuse
# Use findObject to locate the integral variable (Variable:integral)
integralVariable = findObject("Variable:integral")
assert integralVariable is not None, "Integral variable not found or not focused"
# Match the integral variable's position with items in the model to retrieve valueId
value_id = None
for i in range(len(minsky.model.items)):
item = minsky.model.items[i]
if item.x() == integralVariable.x() and item.y() == integralVariable.y():
value_id = item.valueId()
break
value_id=integralVariable.valueId()
# Ensure the value_id is valid
assert value_id is not None, "Integral variable does not have a valueId"
Expand Down
1 change: 0 additions & 1 deletion test/00/plotResize.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ minsky.canvas.mouseUp(300, 200) # Finalize the position
# Attempt to select the PlotWidget
plot_widget = findObject("PlotWidget")
#plot_widget=minsky.canvas.itemFocus() # minsky.canvas.itemFocus() does not work
assert plot_widget is not None, "PlotWidget not found or not focused"
print(f"Focused item: {plot_widget.classType()} at ({plot_widget.x()}, {plot_widget.y()})")
Expand Down

0 comments on commit 1bedb12

Please sign in to comment.