mce-conf.h 2.63 KB
Newer Older
1 2 3 4 5
/**
 * @file mce-conf.h
 * Headers for the configuration option handling for MCE
 * <p>
 * Copyright © 2006-2007 Nokia Corporation and/or its subsidiary(-ies).
6
 * Copyright (C) 2013-2019 Jolla Ltd.
7 8
 * <p>
 * @author David Weinehall <david.weinehall@nokia.com>
9 10
 * @author Santtu Lakkala <ext-santtu.1.lakkala@nokia.com>
 * @author Simo Piiroinen <simo.piiroinen@jollamobile.com>
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
 *
 * mce is free software; you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License
 * version 2.1 as published by the Free Software Foundation.
 *
 * mce is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with mce.  If not, see <http://www.gnu.org/licenses/>.
 */
#ifndef _MCE_CONF_H_
#define _MCE_CONF_H_

#include <glib.h>

29 30 31
gboolean mce_conf_has_group(const gchar *group);
gboolean mce_conf_has_key(const gchar *group, const gchar *key);

32
gboolean mce_conf_get_bool(const gchar *group, const gchar *key,
33
			   const gboolean defaultval);
34
gint mce_conf_get_int(const gchar *group, const gchar *key,
35
		      const gint defaultval);
36
gint *mce_conf_get_int_list(const gchar *group, const gchar *key,
37
			    gsize *length);
38
gchar *mce_conf_get_string(const gchar *group, const gchar *key,
39
			   const gchar *defaultval);
40
gchar **mce_conf_get_string_list(const gchar *group, const gchar *key,
41 42
				 gsize *length);
gchar **mce_conf_get_keys(const gchar *group, gsize *length);
43 44 45 46

gboolean mce_conf_init(void);
void mce_conf_exit(void);

47 48 49 50
const gchar * const *mce_conf_get_touchscreen_event_drivers(void);
const gchar * const *mce_conf_get_keyboard_event_drivers(void);
const gchar * const *mce_conf_get_blacklisted_event_drivers(void);

51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66
/* ========================================================================= *
 * Constant related to button backlight configuration
 * ========================================================================= */

/** Name of the display backlight configuration group */
# define MCE_CONF_BUTTON_BACKLIGHT_GROUP                  "ButtonBacklight"

/** Path to button backlight control file */
# define MCE_CONF_BUTTON_BACKLIGHT_CONTROL_PATH           "ControlPath"

/** Value to write when enabling button backlight */
# define MCE_CONF_BUTTON_BACKLIGHT_CONTROL_VALUE_ENABLE   "ControlValueEnable"

/** Value to write when disabling button backlight */
# define MCE_CONF_BUTTON_BACKLIGHT_CONTROL_VALUE_DISABLE  "ControlValueDisable"

67
#endif /* _MCE_CONF_H_ */