comparison src/Visualization/paranormal/pn/pnlistoption.h @ 0:13389e613d67 trunk

[svn] - initial import of audacious-plugins tree (lots to do)
author nenolod
date Mon, 18 Sep 2006 01:11:49 -0700
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:13389e613d67
1 /* Paranormal - A highly customizable audio visualization library
2 * Copyright (C) 2001 Jamie Gennis <jgennis@mindspring.com>
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Library General Public License for more details.
13 *
14 * You should have received a copy of the GNU Library General Public
15 * License along with this library; if not, write to the Free
16 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17 */
18
19 #ifndef __PN_LIST_OPTION_H__
20 #define __PN_LIST_OPTION_H__
21
22 #include "pnoption.h"
23
24 G_BEGIN_DECLS
25
26 #define PN_TYPE_LIST_OPTION (pn_list_option_get_type ())
27 #define PN_LIST_OPTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PN_TYPE_LIST_OPTION, PnListOption))
28 #define PN_LIST_OPTION_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), PN_TYPE_LIST_OPTION, PnListOptionClass))
29 #define PN_IS_LIST_OPTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PN_TYPE_LIST_OPTION))
30 #define PN_IS_LIST_OPTION_CLASS(class) (G_TYPE_CHECK_CLASS_TYPE ((class), PN_TYPE_LIST_OPTION))
31 #define PN_LIST_OPTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PN_TYPE_LIST_OPTION, PnListOptionClass))
32
33 typedef struct _PnListOption PnListOption;
34 typedef struct _PnListOptionClass PnListOptionClass;
35
36 struct _PnListOption
37 {
38 PnOption parent;
39
40 GArray *items;
41 gint index;
42 };
43
44 struct _PnListOptionClass
45 {
46 PnOptionClass parent_class;
47 };
48
49 /* Creators */
50 GType pn_list_option_get_type (void);
51 PnListOption *pn_list_option_new (const gchar *name,
52 const gchar *desc);
53
54 /* Accessors */
55 void pn_list_option_add_item (PnListOption *list_option,
56 const gchar *item);
57 void pn_list_option_set_index (PnListOption *list_option,
58 guint index);
59 gint pn_list_option_get_index (PnListOption *list_option);
60
61 #endif /* __PN_LIST_OPTION_H__ */