On 29. Nov 2006, at 02:24, Chris Thomas wrote:
[...]
I think what's needed is a separate invocation of tm_dialog, so
you'd have something like a standard event loop (psuedocode):
$tm_dialog -a --parameters '{wrapAround = 1; regExp = 1;}' $TM_NIBS/
SearchDialog.nib
[...get window token in $token...]
# event loop
while( 1 )
{
# wait for user to press something
$tm_dialog --wait-for-input $token
... check plist to determine control clicked, etc ...
}
Ah, that seems pretty simple -- I like that a lot!
With this approach, we can use the current returnArgument: method.
I.e. just make that method not close the window (when window has been
opened as async).
Two things I am wondering about:
1) should tm_dialog -a really return a plist? because we _always_
want just the token?
2) should --wait-for-input only return the arguments given to
returnArgument:… or the full data model? Here I wouldn’t say we
_always_ want the former, but 99% of the time, we would.
_______________________________________________
textmate-dev mailing list
[email protected]
http://lists.macromates.com/mailman/listinfo/textmate-dev