857
|
1 /*
|
|
2 *
|
|
3 * Author: Giacomo Lozito <james@develia.org>, (C) 2005-2007
|
|
4 *
|
|
5 * This program is free software; you can redistribute it and/or modify it
|
|
6 * under the terms of the GNU General Public License as published by the
|
|
7 * Free Software Foundation; either version 2 of the License, or (at your
|
|
8 * option) any later version.
|
|
9 *
|
|
10 * This program is distributed in the hope that it will be useful, but
|
|
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
13 * General Public License for more details.
|
|
14 *
|
|
15 * You should have received a copy of the GNU General Public License along
|
|
16 * with this program; if not, write to the Free Software Foundation, Inc.,
|
|
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
18 *
|
|
19 */
|
|
20
|
|
21 #include "si_cfg.h"
|
|
22 #include "si_common.h"
|
|
23 #include <audacious/configdb.h>
|
|
24
|
|
25 si_cfg_t si_cfg;
|
|
26
|
|
27
|
|
28 void
|
|
29 si_cfg_load ( void )
|
|
30 {
|
|
31 ConfigDb *cfgfile = bmp_cfg_db_open();
|
|
32
|
|
33 if ( !bmp_cfg_db_get_int( cfgfile , "statusicon" ,
|
|
34 "rclick_menu" , &(si_cfg.rclick_menu) ) )
|
|
35 si_cfg.rclick_menu = SI_CFG_RCLICK_MENU_AUD;
|
|
36
|
|
37 bmp_cfg_db_close( cfgfile );
|
|
38 return;
|
|
39 }
|
|
40
|
|
41
|
|
42 void
|
|
43 si_cfg_save ( void )
|
|
44 {
|
|
45 ConfigDb *cfgfile = bmp_cfg_db_open();
|
|
46
|
|
47 bmp_cfg_db_set_int( cfgfile , "statusicon" ,
|
|
48 "rclick_menu" , si_cfg.rclick_menu );
|
|
49
|
|
50 bmp_cfg_db_close( cfgfile );
|
|
51 return;
|
|
52 }
|