From c531dca285a149774664b9e117fe30d1391475c4 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Thu, 13 May 2010 07:27:58 -0400 Subject: [PATCH] Add all_drivers_callback to hooke.plugin.playlist.LoadCommand. I can't imagine the user not wanting to use all available playlists. They still can, but specifiying a sublist is now optional. --- hooke/plugin/playlist.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/hooke/plugin/playlist.py b/hooke/plugin/playlist.py index a374e08..2e94382 100644 --- a/hooke/plugin/playlist.py +++ b/hooke/plugin/playlist.py @@ -48,6 +48,9 @@ PlaylistNameArgument = Argument( Name of the new playlist (defaults to an auto-generated name). """.strip()) +def all_drivers_callback(hooke, command, argument, value): + return hooke.drivers + # Define commands @@ -152,8 +155,8 @@ class LoadCommand (Command): help=""" File name for the input playlist. """.strip()), - Argument(name='drivers', type='driver', optional=False, - count=-1, + Argument(name='drivers', type='driver', optional=True, + count=-1, callback=all_drivers_callback, help=""" Drivers for loading curves. """.strip()), -- 2.26.2