Mercurial > audlegacy
diff src/audtool/audtool_main.c @ 3873:f3341c2d6b9e
audacious remote functions:
- playlist_ins_url_string() and playlist_enqueue_to_temp() have been implemented.
- now get_version() returns audacious version instead of protocol version.
audtool:
- now argc check works properly.
- some cleanups.
author | Yoshiki Yazawa <yaz@cc.rim.or.jp> |
---|---|
date | Tue, 30 Oct 2007 22:12:47 +0900 |
parents | e48f2f4c116d |
children | 86c9abc83fbd |
line wrap: on
line diff
--- a/src/audtool/audtool_main.c Tue Oct 30 18:17:55 2007 +0900 +++ b/src/audtool/audtool_main.c Tue Oct 30 22:12:47 2007 +0900 @@ -111,11 +111,13 @@ /* test suite */ {"<sep>", NULL, "Test suite", 0}, {"activate", test_activate, "activate", 0}, - {"playlist-enqueue-to-temp", test_enqueue_to_temp, "enqueue_to_temp", 1}, - {"toggle-aot", test_toggle_aot, "specify allways on top or not", 1}, // xxx need to be improved. + {"playlist-addurl-to-new-playlist", test_enqueue_to_temp, "adds a url to the newly created playlist", 1}, + {"always-on-top", test_toggle_aot, "on/off always on top", 1}, {"get-skin", test_get_skin, "get skin", 0}, {"set-skin", test_set_skin, "set skin", 1}, {"get-info", test_get_info, "get info", 0}, + {"playlist-insurl", test_ins_url_string, "inserts a url at specified position in the playlist", 2}, + {"get-version", test_get_version, "get version of audacious", 0}, {NULL, NULL, NULL, 0} }; @@ -167,7 +169,9 @@ !g_ascii_strcasecmp(g_strconcat("--", handlers[i].name, NULL), argv[j])) && g_ascii_strcasecmp("<sep>", handlers[i].name)) { - handlers[i].handler(handlers[i].args + 1, &argv[j]); +// handlers[i].handler(handlers[i].args + 1, &argv[j]); + handlers[i].handler(handlers[i].args + 1 < argc - 1 ? handlers[i].args + 1 : argc - 1, + &argv[j]); // to enable argc check --yaz j += handlers[i].args; k++; }