But the issue has been closed, fixed for Mac 6 WIP, however it doesn’t appear to be fixed in 5.5.2 - in any case I can’t get it to return anything but None here.
So that means that any script that needs to choose a folder is now out for the future of Mac V5? That isn’t a very happy situation (to put it nicely)…
Hi Mitch, not sure if this works as a temp workaround, i cannot test it on Mac:
import Eto
import Rhino
def DoSomething():
dialog = Eto.Forms.SelectFolderDialog()
dialog.Directory = None
dialog.Title = "Choose a folder"
rc = dialog.ShowDialog(None)
if rc != Eto.Forms.DialogResult.Ok: return rc
print dialog.Directory
DoSomething()
And @Alain or @curtisw, if you could help here: Why is it not possible to pass the parent window like this:
parent = Rhino.UI.RhinoEtoApp.MainWindow
c = dialog.ShowDialog(parent)
it gave me a “non implemented” error on Windows. I’ve tried all kind of variations eg. Rhino.RhinoApp.MainWindow() gives me this error:
Message: expected Window, got RhinoWindow
the purpose of passing the parent window is to make the dialog block Rhino while a folder is chosen. If i pass None as shown above, this does not happen and Rhino is still accessable.
Well, it WAS working in the past. The only thing that was wrong was that the title and/or message arguments weren’t working… I have past scripts that worked with this exception…