diff options
author | Viktor Semykin <thesame.ml@gmail.com> | 2010-07-04 19:02:19 +0300 |
---|---|---|
committer | Viktor Semykin <thesame.ml@gmail.com> | 2010-07-04 19:02:19 +0300 |
commit | 5e64ac2297992c8cfe35233fc93585f7066a6faa (patch) | |
tree | b8b181b60b65a0e39081b16f61834b61b8da09bd /plugins/lastfm | |
parent | ffd1a10e7f34a0a9201297db12aadbf74d7c59c8 (diff) |
added support of plugins actions for global hotkeys
Diffstat (limited to 'plugins/lastfm')
-rw-r--r-- | plugins/lastfm/lastfm.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins/lastfm/lastfm.c b/plugins/lastfm/lastfm.c index 82b2db91..c674a5fa 100644 --- a/plugins/lastfm/lastfm.c +++ b/plugins/lastfm/lastfm.c @@ -23,8 +23,8 @@ #include <curl/curl.h> #include "../../deadbeef.h" -//#define trace(...) { fprintf(stderr, __VA_ARGS__); } -#define trace(fmt,...) +#define trace(...) { fprintf(stderr, __VA_ARGS__); } +//#define trace(fmt,...) #define LFM_TESTMODE 0 #define LFM_IGNORE_RULES 0 @@ -825,7 +825,7 @@ lastfm_stop (void) { } static int -lfm_action_lookup (DB_playItem_t *it, void *data) +lfm_action_lookup (DB_plugin_action_t *action, DB_playItem_t *it) { const char *artist = deadbeef->pl_find_meta (it, "artist"); const char *title = deadbeef->pl_find_meta (it, "title"); @@ -857,6 +857,7 @@ lfm_action_love (DB_playItem_t *it, void *data) static DB_plugin_action_t love_action = { .title = "Love at Last.fm", + .name = "lfm_love", .flags = DB_ACTION_SINGLE_TRACK, .callback = lfm_action_love, .next = NULL @@ -864,6 +865,7 @@ static DB_plugin_action_t love_action = { static DB_plugin_action_t lookup_action = { .title = "Lookup at Last.fm", + .name = "lfm_lookup", .flags = DB_ACTION_SINGLE_TRACK, .callback = lfm_action_lookup, .next = &love_action |