Mercurial > audlegacy-plugins
annotate src/lastfm/lastfm.h @ 1201:2ae8155baef1
First cleanups
author | michi@tux.homenetwork |
---|---|
date | Mon, 02 Jul 2007 15:53:49 +0200 |
parents | 0ae013f630fa |
children | d4efe4889489 |
rev | line source |
---|---|
982 | 1 #define LASTFM_HANDSHAKE_URL "http://ws.audioscrobbler.com/radio/handshake.php?version=1.1.1&platform=linux&username=%s&passwordmd5=%s&debug=0&language=jp" |
2 #define LASTFM_ADJUST_URL "http://ws.audioscrobbler.com/radio/adjust.php?session=%s&url=%s&debug=0" | |
3 #define LASTFM_METADATA_URL "http://ws.audioscrobbler.com/radio/np.php?session=%s&debug=0" | |
4 | |
5 #define LASTFM_CURL_TIMEOUT 10 | |
1036 | 6 |
982 | 7 |
1200
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
8 #define LASTFM_LOGIN_OK 0 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
9 #define LASTFM_LOGIN_ERROR 1 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
10 #define LASTFM_MISSING_LOGIN_DATA 2 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
11 #define LASTFM_SESSION_MISSING 4 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
12 #define LASTFM_ADJUST_OK 0 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
13 |
0ae013f630fa
mowgli transition, and some fixes
Cristi Magherusan <majeru@atheme-project.org>
parents:
1044
diff
changeset
|
14 |
982 | 15 typedef struct |
16 { | |
17 VFSFile *proxy_fd; | |
18 gchar *lastfm_session_id; | |
19 gchar *lastfm_mp3_stream_url; | |
20 gchar *lastfm_station_name; | |
21 gchar *lastfm_artist; | |
22 gchar *lastfm_title; | |
23 gchar *lastfm_album; | |
24 gchar *lastfm_cover; | |
1010
8bad1b46ef78
[svn] - make this compile again and indent properly
nenolod
parents:
982
diff
changeset
|
25 unsigned int lastfm_duration; |
8bad1b46ef78
[svn] - make this compile again and indent properly
nenolod
parents:
982
diff
changeset
|
26 unsigned int lastfm_progress; |
1036 | 27 GThread *metadata_thread; |
982 | 28 int login_count; |
29 } LastFM; | |
30 | |
31 VFSFile *lastfm_vfs_fopen_impl(const gchar * path, const gchar * mode); | |
32 | |
33 size_t lastfm_vfs_fread_impl(gpointer ptr, size_t size, size_t nmemb, VFSFile * file); | |
34 | |
35 size_t lastfm_vfs_fwrite_impl(gconstpointer ptr, size_t size, size_t nmemb, VFSFile * file); | |
36 | |
37 gint lastfm_vfs_getc_impl(VFSFile * stream); | |
38 | |
39 gint lastfm_vfs_ungetc_impl(gint c, VFSFile * stream); | |
40 | |
41 gint lastfm_vfs_fseek_impl(VFSFile * file, glong offset, gint whence); | |
42 | |
43 void lastfm_vfs_rewind_impl(VFSFile * file); | |
44 | |
45 glong lastfm_vfs_ftell_impl(VFSFile * file); | |
46 | |
47 gboolean lastfm_vfs_feof_impl(VFSFile * file); | |
48 | |
49 gint lastfm_vfs_truncate_impl(VFSFile * file, glong size); | |
50 | |
51 off_t lastfm_vfs_fsize_impl(VFSFile * file); | |
52 | |
53 gint lastfm_vfs_fclose_impl(VFSFile * file); | |
54 | |
55 gchar *lastfm_vfs_metadata_impl(VFSFile * file, const gchar * field); | |
56 | |
1036 | 57 static void parse_metadata(LastFM * handle,GString * res); |
58 | |
1044
b1128efde471
[svn] - get rid of all warnings gcc 4.2.0 emits with my build configuration.
yaz
parents:
1036
diff
changeset
|
59 static gpointer lastfm_get_metadata(gpointer arg); |
982 | 60 |
61 static gboolean lastfm_login(void); | |
62 | |
63 LowlevelPlugin *get_lplugin_info(void); | |
64 |