aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKalle Wallin <kaw@linux.se>2004-06-18 14:19:23 +0000
committerKalle Wallin <kaw@linux.se>2004-06-18 14:19:23 +0000
commit49d3277a7345108f10322712852f3f1f1df92eb6 (patch)
tree9607cc1a504e92deeff5bd140ddf1093438a67d5 /src
parente1253697423aa4c1d55583c8975e02a9e2161434 (diff)
downloadmpd-49d3277a7345108f10322712852f3f1f1df92eb6.tar.gz
mpd-49d3277a7345108f10322712852f3f1f1df92eb6.tar.xz
mpd-49d3277a7345108f10322712852f3f1f1df92eb6.zip
Added the mpdclient_cmd_add_path function
git-svn-id: https://svn.musicpd.org/ncmpc/trunk@1553 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r--src/mpdclient.c12
-rw-r--r--src/mpdclient.h1
2 files changed, 13 insertions, 0 deletions
diff --git a/src/mpdclient.c b/src/mpdclient.c
index bb6c90fa9..1069f8ef5 100644
--- a/src/mpdclient.c
+++ b/src/mpdclient.c
@@ -330,6 +330,18 @@ mpdclient_cmd_volume(mpdclient_t *c, gint value)
}
gint
+mpdclient_cmd_add_path(mpdclient_t *c, gchar *path)
+{
+ gint retval;
+ gchar *path_utf8 = locale_to_utf8(path);
+
+ mpd_sendAddCommand(c->connection, path_utf8);
+ retval=mpdclient_finish_command(c);
+ g_free(path_utf8);
+ return retval;
+}
+
+gint
mpdclient_cmd_add(mpdclient_t *c, mpd_Song *song)
{
gint retval = 0;
diff --git a/src/mpdclient.h b/src/mpdclient.h
index 7debd8050..c5df09ed8 100644
--- a/src/mpdclient.h
+++ b/src/mpdclient.h
@@ -83,6 +83,7 @@ gint mpdclient_cmd_random(mpdclient_t *c, gint value);
gint mpdclient_cmd_crossfade(mpdclient_t *c, gint value);
gint mpdclient_cmd_db_update(mpdclient_t *c, gchar *path);
gint mpdclient_cmd_volume(mpdclient_t *c, gint value);
+gint mpdclient_cmd_add_path(mpdclient_t *c, gchar *path);
gint mpdclient_cmd_add(mpdclient_t *c, mpd_Song *song);
gint mpdclient_cmd_delete(mpdclient_t *c, gint index);