X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=plugins%2Ftext%2Fncurses.c;h=20ad92672d93c019cca161ba08297d66001933d1;hb=583c6553f6761421260d86bbc21b5b3169c04319;hp=0ae3512e75a9193c113e4926069d8e30dd03d9d3;hpb=3bb7a5371e29b608e29851b9f1366a12a3505afe;p=vlc diff --git a/plugins/text/ncurses.c b/plugins/text/ncurses.c index 0ae3512e75..20ad92672d 100644 --- a/plugins/text/ncurses.c +++ b/plugins/text/ncurses.c @@ -21,6 +21,7 @@ *****************************************************************************/ #define MODULE_NAME ncurses +#include "modules_inner.h" /***************************************************************************** * Preamble @@ -35,7 +36,6 @@ #include "mtime.h" #include "modules.h" -#include "modules_inner.h" /***************************************************************************** * Building configuration tree @@ -48,7 +48,7 @@ MODULE_CONFIG_END /***************************************************************************** * Capabilities defined in the other files. ******************************************************************************/ -extern void intf_getfunctions( function_list_t * p_function_list ); +void _M( intf_getfunctions )( function_list_t * p_function_list ); /***************************************************************************** * InitModule: get the module structure and configuration. @@ -58,7 +58,7 @@ extern void intf_getfunctions( function_list_t * p_function_list ); * be unloaded later to save memory, and we want to be able to access this * data even after the module has been unloaded. *****************************************************************************/ -int InitModule( module_t * p_module ) +MODULE_INIT { p_module->psz_name = MODULE_STRING; p_module->psz_longname = "ncurses interface module"; @@ -78,7 +78,7 @@ int InitModule( module_t * p_module ) * be set to 0 and calls to NeedModule() be made to increment it. To unload * the module, one has to wait until i_usage == 0 and call DeactivateModule(). *****************************************************************************/ -int ActivateModule( module_t * p_module ) +MODULE_ACTIVATE { p_module->p_functions = malloc( sizeof( module_functions_t ) ); if( p_module->p_functions == NULL ) @@ -86,7 +86,7 @@ int ActivateModule( module_t * p_module ) return( -1 ); } - intf_getfunctions( &p_module->p_functions->intf ); + _M( intf_getfunctions )( &p_module->p_functions->intf ); p_module->p_config = p_config; @@ -100,7 +100,7 @@ int ActivateModule( module_t * p_module ) * returns, i_usage can be set to -1 and the module unloaded. Be careful to * lock usage_lock during the whole process. *****************************************************************************/ -int DeactivateModule( module_t * p_module ) +MODULE_DEACTIVATE { free( p_module->p_functions );