-
1. Re: window.close not working on indesign cc2014
poortip87 Oct 21, 2014 1:25 AM (in response to poortip87)I went ahead and wrote the below code for close button handler,
var openedWindows:Array = NativeApplication.nativeApplication.openedWindows; var i:uint; var count:uint = openedWindows.length; for(i; i < count; i++) { openedWindows[i].close(); }This closed the parent application, but the dialog Window remained as it is..
What is happening? Is this a bug with Adobe?
What alternative do I have if I want to open another dialog?
-
2. Re: window.close not working on indesign cc2014
Harbs. Oct 21, 2014 2:34 AM (in response to poortip87)CSXSWindowType.PANEL has always been a bit funky. It hasn't even worked in all the apps. If you can make it MODAL instead, I'd do that.
Harbs
-
3. Re: window.close not working on indesign cc2014
poortip87 Oct 21, 2014 2:55 AM (in response to Harbs.)Okay, if I change the window type to Modal, it closes okay. If window type is panel or modal-less, it doesn't close.
I need my window to be able to lose focus, which cannot be possible in case of modal dialog. I am showing image preview in the dialog window by clicking on its thumbnail in the main app. I want the user to be able to change the preview by clicking on the thumbnail without closing the dialog.
Everything else is okay, the close function is ruining it.
Any suggestions?
-
4. Re: window.close not working on indesign cc2014
Harbs. Oct 21, 2014 6:41 AM (in response to poortip87)Any suggestions?
I don't know how complex your UI is. If ScriptUI is an option, I'd probably go with that. Another option would be to make a separate window extension described in your manifest instead of creating it on the fly. You'd then communicate with it / launch it using CSXSInterface. (I don't know if that will help.) Lastly, you might be able to cobble something together using system native tools or Xojo and make a floating window look like it's part of InDesign when it's really not.
HTH,
Harbs



