Mercurial > audlegacy
annotate src/audacious/discovery.h @ 4747:0cc36efdbe07
Don't use a static buffer, but g_strdup_vprintf().
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 30 Jul 2008 17:15:13 +0300 |
parents | 2eee464379dc |
children |
rev | line source |
---|---|
3227
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
1 /* BMP - Cross-platform multimedia player |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
2 * Copyright (C) 2003-2004 BMP development team. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
3 * |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
4 * Based on XMMS: |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
5 * Copyright (C) 1998-2003 XMMS development team. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
6 * |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
7 * This program is free software; you can redistribute it and/or modify |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
8 * it under the terms of the GNU General Public License as published by |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
9 * the Free Software Foundation; under version 3 of the License. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
10 * |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
11 * This program is distributed in the hope that it will be useful, |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
14 * GNU General Public License for more details. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
15 * |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
16 * You should have received a copy of the GNU General Public License |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
17 * along with this program. If not, see <http://www.gnu.org/licenses>. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
18 * |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
19 * The Audacious team does not consider modular code linking to |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
20 * Audacious or using our public API to be a derived work. |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
21 */ |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
22 |
4557
2eee464379dc
Clean up header multiple inclusion guards (e.g. #ifndef FOO_H/#define FOO_H)
Matti Hamalainen <ccr@tnsp.org>
parents:
3455
diff
changeset
|
23 #ifndef AUDACIOUS_DISCOVERY_H |
2eee464379dc
Clean up header multiple inclusion guards (e.g. #ifndef FOO_H/#define FOO_H)
Matti Hamalainen <ccr@tnsp.org>
parents:
3455
diff
changeset
|
24 #define AUDACIOUS_DISCOVERY_H |
3227
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
25 |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
26 #include <glib.h> |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
27 |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
28 typedef struct _DiscoveryPluginData DiscoveryPluginData; |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
29 |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
30 struct _DiscoveryPluginData { |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
31 GList *discovery_list; |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
32 GList *enabled_list; |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
33 }; |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
34 |
3384
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
35 GList * discovery_devices; |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
36 typedef struct _discovery_device_t discovery_device_t; |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
37 struct _discovery_device_t { |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
38 gchar *device_name; /*some kind of description*/ |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
39 gchar *device_address; /*some kind of device ID*/ |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
40 GList *device_playlist; /*contains all the songs on the device*/ |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
41 }; |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
42 |
7ac9c5c6b44e
fixed the interface
Cristi Magherusan <majeru@atheme-project.org>
parents:
3227
diff
changeset
|
43 |
3227
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
44 GList *get_discovery_list(void); |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
45 GList *get_discovery_enabled_list(void); |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
46 void enable_discovery_plugin(gint i, gboolean enable); |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
47 gchar *discovery_stringify_enabled_list(void); |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
48 void discovery_enable_from_stringified_list(const gchar * list); |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
49 |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
50 extern DiscoveryPluginData dp_data; |
2619f4c62abe
added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents:
diff
changeset
|
51 |
4557
2eee464379dc
Clean up header multiple inclusion guards (e.g. #ifndef FOO_H/#define FOO_H)
Matti Hamalainen <ccr@tnsp.org>
parents:
3455
diff
changeset
|
52 #endif /* AUDACIOUS_DISCOVERY_H */ |