correctly open folders in a new window on mac os x

this fixes #143 where "open in new window" would open new windows in a new app instance.
with this fix new windows will be opened in the running app instance.