diff options
author | Alexey Yakovenko <wakeroid@gmail.com> | 2010-07-29 22:13:48 +0200 |
---|---|---|
committer | Alexey Yakovenko <wakeroid@gmail.com> | 2010-07-29 22:15:08 +0200 |
commit | 7134c52b27398706a15dc4dbd37bb78120ce9a6e (patch) | |
tree | 33e392448f82284dcaa860017d6ae77b10589841 /plugins/shellexec | |
parent | a47247a948e47f6bbadcf15f031af902d1f42551 (diff) |
all global hotkey actions code is now exported as standard plugin actions
improved global hotkeys gui configuration in gtkui
added long requested Play/Pause action/hotkey
fixed few memory leaks in gtkui
Diffstat (limited to 'plugins/shellexec')
-rw-r--r-- | plugins/shellexec/shellexec.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/shellexec/shellexec.c b/plugins/shellexec/shellexec.c index 84a77bad..af1078c1 100644 --- a/plugins/shellexec/shellexec.c +++ b/plugins/shellexec/shellexec.c @@ -101,11 +101,13 @@ shx_callback (Shx_action_t *action, DB_playItem_t *it) static DB_plugin_action_t * shx_get_actions (DB_playItem_t *it) { + int is_local = it ? deadbeef->is_local_file (it->fname) : 1; + Shx_action_t *action; for (action = actions; action; action = (Shx_action_t *)action->parent.next) { - if (((action->shx_flags & SHX_ACTION_LOCAL_ONLY) && !deadbeef->is_local_file (it->fname)) || - ((action->shx_flags & SHX_ACTION_REMOTE_ONLY) && deadbeef->is_local_file (it->fname))) + if (((action->shx_flags & SHX_ACTION_LOCAL_ONLY) && !is_local) || + ((action->shx_flags & SHX_ACTION_REMOTE_ONLY) && is_local)) action->parent.flags |= DB_ACTION_DISABLED; else action->parent.flags &= ~DB_ACTION_DISABLED; |