12#ifndef __PREFS_INT_H__
13#define __PREFS_INT_H__
16#include "ws_symbol_export.h"
58typedef void (*pref_custom_free_cb) (
pref_t* pref);
59typedef void (*pref_custom_reset_cb) (
pref_t* pref);
60typedef prefs_set_pref_e (*pref_custom_set_cb) (
pref_t* pref,
const char* value,
unsigned int* changed_flags);
63typedef const char * (*pref_custom_type_name_cb) (void);
64typedef char * (*pref_custom_type_description_cb) (void);
65typedef bool (*pref_custom_is_default_cb) (
pref_t* pref);
66typedef char * (*pref_custom_to_str_cb) (
pref_t* pref,
bool default_val);
70 pref_custom_free_cb free_cb;
71 pref_custom_reset_cb reset_cb;
72 pref_custom_set_cb set_cb;
74 pref_custom_type_name_cb type_name_cb;
75 pref_custom_type_description_cb type_description_cb;
76 pref_custom_is_default_cb is_default_cb;
77 pref_custom_to_str_cb to_str_cb;
95 PREF_PROTO_TCP_SNDAMB_ENUM,
121const char* prefs_get_description(
pref_t *pref);
124const char* prefs_get_title(
pref_t *pref);
127const char* prefs_get_name(
pref_t *pref);
130int prefs_get_type(
pref_t *pref);
132WS_DLL_PUBLIC uint32_t prefs_get_max_value(
pref_t *pref);
192bool prefs_set_range_value_work(
pref_t *pref,
const char *value,
193 bool return_range_errors,
unsigned int *changed_flags);
197prefs_set_stashed_range_value(
pref_t *pref,
const char *value);
210WS_DLL_PUBLIC
unsigned int prefs_set_bool_value(
pref_t *pref,
bool value, pref_source_t source);
211WS_DLL_PUBLIC
bool prefs_get_bool_value(
pref_t *pref, pref_source_t source);
212WS_DLL_PUBLIC
void prefs_invert_bool_value(
pref_t *pref, pref_source_t source);
214WS_DLL_PUBLIC
unsigned int prefs_set_uint_value(
pref_t *pref,
unsigned value, pref_source_t source);
215WS_DLL_PUBLIC
unsigned prefs_get_uint_base(
pref_t *pref);
216WS_DLL_PUBLIC
unsigned prefs_get_uint_value(
pref_t *pref, pref_source_t source);
219WS_DLL_PUBLIC
unsigned int prefs_set_enum_value(
pref_t *pref,
int value, pref_source_t source);
220WS_DLL_PUBLIC
unsigned int prefs_set_enum_string_value(
pref_t *pref,
const char *value, pref_source_t source);
221WS_DLL_PUBLIC
int prefs_get_enum_value(
pref_t *pref, pref_source_t source);
223WS_DLL_PUBLIC
bool prefs_get_enum_radiobuttons(
pref_t *pref);
225WS_DLL_PUBLIC
bool prefs_set_color_value(
pref_t *pref,
color_t value, pref_source_t source);
226WS_DLL_PUBLIC
color_t* prefs_get_color_value(
pref_t *pref, pref_source_t source);
228WS_DLL_PUBLIC
unsigned int prefs_set_custom_value(
pref_t *pref,
const char *value, pref_source_t source);
230WS_DLL_PUBLIC
unsigned int prefs_set_string_value(
pref_t *pref,
const char* value, pref_source_t source);
231WS_DLL_PUBLIC
char* prefs_get_string_value(
pref_t *pref, pref_source_t source);
235WS_DLL_PUBLIC
bool prefs_set_range_value(
pref_t *pref,
range_t *value, pref_source_t source);
236WS_DLL_PUBLIC
range_t* prefs_get_range_value_real(
pref_t *pref, pref_source_t source);
238WS_DLL_PUBLIC
bool prefs_add_decode_as_value(
pref_t *pref,
unsigned value,
bool replace);
239WS_DLL_PUBLIC
bool prefs_remove_decode_as_value(
pref_t *pref,
unsigned value,
bool set_default);
241WS_DLL_PUBLIC
unsigned int prefs_set_password_value(
pref_t *pref,
const char* value, pref_source_t source);
242WS_DLL_PUBLIC
char* prefs_get_password_value(
pref_t *pref, pref_source_t source);
244WS_DLL_PUBLIC
bool prefs_add_list_value(
pref_t *pref,
void *value, pref_source_t source);
245WS_DLL_PUBLIC GList* prefs_get_list_value(
pref_t *pref, pref_source_t source);
247WS_DLL_PUBLIC
void reset_pref(
pref_t *pref);
268prefs_pref_is_default(
pref_t *pref);
286 bool handle_decode_as;
WS_DLL_PUBLIC void prefs_set_effect_flags(pref_t *pref, unsigned int flags)
Definition prefs.c:6518
WS_DLL_PUBLIC void prefs_set_effect_flags_by_name(module_t *module, const char *pref, unsigned int flags)
Definition prefs.c:6529
WS_DLL_PUBLIC unsigned pref_unstash(pref_t *pref, void *unstash_data_p)
Definition prefs.c:2069
WS_DLL_PUBLIC char * join_string_list(GList *sl)
Definition prefs.c:4107
prefs_set_pref_e(* pref_set_pair_cb)(char *key, const char *value, void *private_data, bool return_range_errors)
Definition prefs-int.h:118
WS_DLL_PUBLIC void prefs_set_module_effect_flags(module_t *module, unsigned int flags)
Definition prefs.c:6544
WS_DLL_PUBLIC unsigned int prefs_get_module_effect_flags(module_t *module)
Definition prefs.c:6535
WS_DLL_PUBLIC void prefs_range_remove_value(pref_t *pref, uint32_t val)
Definition prefs.c:1731
WS_DLL_PUBLIC unsigned pref_stash(pref_t *pref, void *unused)
WS_DLL_PUBLIC int read_prefs_file(const char *pf_path, FILE *pf, pref_set_pair_cb pref_set_pair_fct, void *private_data)
Definition prefs.c:4753
WS_DLL_PUBLIC void reset_stashed_pref(pref_t *pref)
Definition prefs.c:2222
WS_DLL_PUBLIC void prefs_range_add_value(pref_t *pref, uint32_t val)
Definition prefs.c:1725
WS_DLL_PUBLIC unsigned int prefs_get_effect_flags(pref_t *pref)
Definition prefs.c:6509
WS_DLL_PUBLIC unsigned pref_clean_stash(pref_t *pref, void *unused)
WS_DLL_PUBLIC void prefs_read_module(const char *name, const char *app_env_var_prefix)
Definition prefs.c:4589
prefs_set_pref_e
Definition prefs.h:993
Internal representation of a wmem balanced tree.
Definition wmem_tree-int.h:81
RGB color representation with 16-bit precision per channel.
Definition color.h:27
Definition prefs-int.h:69
Definition prefs-int.h:27
unsigned int effect_flags
Definition prefs-int.h:48
GList * prefs
Definition prefs-int.h:33
bool use_gui
Definition prefs-int.h:41
wmem_tree_t * submodules
Definition prefs-int.h:35
const char * description
Definition prefs-int.h:30
const char * name
Definition prefs-int.h:28
bool obsolete
Definition prefs-int.h:38
struct pref_module * parent
Definition prefs-int.h:34
unsigned int prefs_changed_flags
Definition prefs-int.h:37
void(* apply_cb)(void)
Definition prefs-int.h:32
int numprefs
Definition prefs-int.h:36
const char * title
Definition prefs-int.h:29
const char * help
Definition prefs-int.h:31
Definition prefs-int.h:280
Definition prefs-int.h:53