On 15. Nov 2006, at 15:16, Jay Soffian wrote:
On Nov 15, 2006, at 8:57 AM, Allan Odgaard wrote:
At that point, you got to ask yourself why use tm_dialog at all, i.e. why not write it in Objective-C or use one of the Python/Ruby Cocoa wrappers.
True but then its windows wouldn't be owned by TextMate ... wasn't that part of the point of tm_dialog?
It was one of the advantages with the current implementation, yes. But the point with tm_dialog is to provide a simple way to bring up dialogs slightly more complex than what CocoaDialog offers -- while I do see a few possible evolutions of tm_dialog, like the ability to have it return and receive a new data model while the dialog is still up (using the stdin/out pipe), I don’t plan to extend it much further, as far better results can be obtained by simply writing “real” code instead of relying on what tm_dialog offers.
If your reason for wanting to pursue tm_dialog with callback hooks is to have windows owned by TM, then I think a better approach would be to look into extending the TM dialog server protocol with a method more suitable for callers who want to have code running while the dialog is up -- or perhaps more appropriately, introduce an API for dynamically loadable (and unloadable) plug-ins.