diff options
author | Max Kellermann <max@duempel.org> | 2013-01-28 23:12:10 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-01-28 23:12:10 +0100 |
commit | 5934ccbb74e1a8470426107bf7244cb9f50e7588 (patch) | |
tree | 606063996461638ae598274628c0da9f5873f5d5 /src | |
parent | e39969a0d0b943e55463a537d404ef9e1f6a0a28 (diff) |
input/despotify: rename class
Diffstat (limited to 'src')
-rw-r--r-- | src/input/DespotifyInputPlugin.cxx | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/src/input/DespotifyInputPlugin.cxx b/src/input/DespotifyInputPlugin.cxx index 46960b1f7..c41dcf25f 100644 --- a/src/input/DespotifyInputPlugin.cxx +++ b/src/input/DespotifyInputPlugin.cxx @@ -37,7 +37,7 @@ extern "C" { #include <stdio.h> -struct input_despotify { +struct DespotifyInputStream { struct input_stream base; struct despotify_session *session; @@ -48,9 +48,8 @@ struct input_despotify { bool eof; }; - static void -refill_buffer(struct input_despotify *ctx) +refill_buffer(DespotifyInputStream *ctx) { /* Wait until there is data */ while (1) { @@ -77,7 +76,7 @@ refill_buffer(struct input_despotify *ctx) static void callback(G_GNUC_UNUSED struct despotify_session* ds, int sig, G_GNUC_UNUSED void* data, void* callback_data) { - struct input_despotify *ctx = (struct input_despotify *)callback_data; + DespotifyInputStream *ctx = (DespotifyInputStream *)callback_data; switch (sig) { case DESPOTIFY_NEW_TRACK: @@ -105,7 +104,7 @@ input_despotify_open(const char *url, Mutex &mutex, Cond &cond, G_GNUC_UNUSED GError **error_r) { - struct input_despotify *ctx; + DespotifyInputStream *ctx; struct despotify_session *session; struct ds_link *ds_link; struct ds_track *track; @@ -127,7 +126,7 @@ input_despotify_open(const char *url, return NULL; } - ctx = g_new(struct input_despotify, 1); + ctx = g_new(DespotifyInputStream, 1); memset(ctx, 0, sizeof(*ctx)); track = despotify_link_get_track(session, ds_link); @@ -166,7 +165,7 @@ static size_t input_despotify_read(struct input_stream *is, void *ptr, size_t size, G_GNUC_UNUSED GError **error_r) { - struct input_despotify *ctx = (struct input_despotify *)is; + DespotifyInputStream *ctx = (DespotifyInputStream *)is; size_t to_cpy = size; if (ctx->len_available == 0) @@ -185,7 +184,7 @@ input_despotify_read(struct input_stream *is, void *ptr, size_t size, static void input_despotify_close(struct input_stream *is) { - struct input_despotify *ctx = (struct input_despotify *)is; + DespotifyInputStream *ctx = (DespotifyInputStream *)is; if (ctx->tag != NULL) tag_free(ctx->tag); @@ -199,7 +198,7 @@ input_despotify_close(struct input_stream *is) static bool input_despotify_eof(struct input_stream *is) { - struct input_despotify *ctx = (struct input_despotify *)is; + DespotifyInputStream *ctx = (DespotifyInputStream *)is; return ctx->eof; } @@ -215,7 +214,7 @@ input_despotify_seek(G_GNUC_UNUSED struct input_stream *is, static struct tag * input_despotify_tag(struct input_stream *is) { - struct input_despotify *ctx = (struct input_despotify *)is; + DespotifyInputStream *ctx = (DespotifyInputStream *)is; struct tag *tag = ctx->tag; ctx->tag = NULL; |