DOCUMENTOPENED conveniently gives the opened document (I mean sender.object()), but DOCUMENTCLOSED returns GSWindowController. Is there a way to get which document was closed?
You can ask the window controller for its document (
But seems like it gives a different id (2) from when the document is open (1):
<native-selector document of <GSWindowController: 0x7fc87e643230>>
It also has no document.font and other properties. Am I doing something wrong?
You need to do
windowController = document.windowContoller()
When you get a
native-selector, you need to add
() to the property.
Oh, got it, thank you!