Snakebite
October 13th, 2002, 03:55 PM
I have a suggestion for the next version of the plugin API.
My plugin would benefit from better access to the target of commands. Today, my plugin can only enumerate targets of it's own commands. Also, today the assumption is that targets are only enumerated during the *execution* of a command.
I suggest a function like target_enum that will take the id of *any* command, not restricted to the commands of my plugin, and callback a function in my plugin.
I also suggest a function like the above, but that will assume the target of the currently selected command. That way, the settings dialog can make use of the current command's target while the settings are being edited. That is, one should not have to save the command before the targets can be enumerated.
Also, don't forget my suggestion to send state information to the callback function! I hate globals. :)
So when can we see this added to the API? :)
My plugin would benefit from better access to the target of commands. Today, my plugin can only enumerate targets of it's own commands. Also, today the assumption is that targets are only enumerated during the *execution* of a command.
I suggest a function like target_enum that will take the id of *any* command, not restricted to the commands of my plugin, and callback a function in my plugin.
I also suggest a function like the above, but that will assume the target of the currently selected command. That way, the settings dialog can make use of the current command's target while the settings are being edited. That is, one should not have to save the command before the targets can be enumerated.
Also, don't forget my suggestion to send state information to the callback function! I hate globals. :)
So when can we see this added to the API? :)