0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 03:52:22 +02:00

Add a type name for the test function

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@14286 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2004-12-31 14:57:12 +00:00
parent d0b713ad24
commit 1f74d67f87

View File

@ -13,13 +13,15 @@
#define OPT_ARG_INT 1
#define OPT_ARG_STR 2
typedef int (*opt_test_f)(void *);
/** simple structure for defining the option name, type and storage location */
typedef struct opt_s
{
char * name; ///< string that identifies the option
int type; ///< option type as defined in subopt-helper.h
void * valp; ///< pointer to the mem where the value should be stored
int (* test)(void *); ///< argument test func ( optional )
opt_test_f test; ///< argument test func ( optional )
int set; ///< Is set internally by the parser if the option was found.
///< Don't use it at initialization of your opts, it will be
///< overriden anyway!