23#ifndef VLC_EXTENSIONS_H
24#define VLC_EXTENSIONS_H
142 int i_flag,
bool b_default )
153#define extension_Activate( mgr, ext ) \
154 extension_Control( mgr, EXTENSION_ACTIVATE, ext )
157#define extension_Trigger( mgr, ext ) \
158 extension_Control( mgr, EXTENSION_TRIGGER, ext )
161#define extension_Deactivate( mgr, ext ) \
162 extension_Control( mgr, EXTENSION_DEACTIVATE, ext )
165#define extension_IsActivated( mgr, ext ) \
166 vlc_extension_GetBool( mgr, ext, EXTENSION_IS_ACTIVATED, false )
169#define extension_HasMenu( mgr, ext ) \
170 vlc_extension_GetBool( mgr, ext, EXTENSION_HAS_MENU, false )
212#define extension_TriggerOnly( mgr, ext ) \
213 vlc_extension_GetBool( mgr, ext, EXTENSION_TRIGGER_ONLY, false )
272 command.
p_dlg = p_dialog;
273 command.
event = event;
282#define extension_DialogClosed( dlg ) \
283 extension_DialogCommand( dlg, EXTENSION_EVENT_CLOSE, NULL )
289#define extension_WidgetClicked( dlg, wdg ) \
290 extension_DialogCommand( dlg, EXTENSION_EVENT_CLICK, wdg )
#define VLC_API
Definition fourcc_gen.c:31
#define VLC_SUCCESS
No error.
Definition vlc_common.h:478
static int var_SetAddress(vlc_object_t *p_obj, const char *psz_name, void *ptr)
Set the value of a pointer variable.
Definition vlc_variables.h:392
static thread_local struct @85 state
Command to pass to the extension dialog owner.
Definition vlc_extensions.h:235
void * p_data
Opaque data to send.
Definition vlc_extensions.h:238
extension_dialog_t * p_dlg
Destination dialog.
Definition vlc_extensions.h:236
extension_dialog_event_e event
Event,.
Definition vlc_extensions.h:237
Dialog descriptor for extensions.
Definition vlc_extensions.h:244
vlc_cond_t cond
Signaled == UI is done working on the dialog.
Definition vlc_extensions.h:259
bool b_hide
Hide this dialog (!b_hide shows)
Definition vlc_extensions.h:253
char * psz_title
Title for the Dialog (in TitleBar)
Definition vlc_extensions.h:247
int i_height
Height hint in pixels (may be discarded)
Definition vlc_extensions.h:249
vlc_object_t * p_object
Owner object (callback on "dialog-event")
Definition vlc_extensions.h:245
void * p_sys_intf
GUI private pointer.
Definition vlc_extensions.h:257
int i_width
Width hint in pixels (may be discarded)
Definition vlc_extensions.h:248
void * p_sys
Dialog private pointer.
Definition vlc_extensions.h:256
struct extension_dialog_t::@224 widgets
Widgets owned by the dialog.
bool b_kill
Kill this dialog.
Definition vlc_extensions.h:254
vlc_mutex_t lock
Dialog mutex.
Definition vlc_extensions.h:258
Extension descriptor: name, title, author, ...
Definition vlc_extensions.h:38
char * psz_version
Version (ro)
Definition vlc_extensions.h:51
struct vlc_logger * logger
The LibVLC logger to use for the extension.
Definition vlc_extensions.h:44
char * psz_url
A URL to the official page (ro)
Definition vlc_extensions.h:52
char * psz_shortdescription
Short description (eg.
Definition vlc_extensions.h:54
char * psz_name
Real name of the extension (ro)
Definition vlc_extensions.h:47
char * p_icondata
Embedded data for the icon (ro)
Definition vlc_extensions.h:55
char * psz_description
Full description (ro)
Definition vlc_extensions.h:53
char * psz_title
Display title (ro)
Definition vlc_extensions.h:49
void * p_sys
Reserved for the manager module.
Definition vlc_extensions.h:39
char * psz_author
Author of the extension (ro)
Definition vlc_extensions.h:50
int i_icondata_size
Size of that data.
Definition vlc_extensions.h:56
Definition vlc_extensions.h:316
int i_id
Identifier for the extension module (weird behavior may occur if not unique)
Definition vlc_extensions.h:317
bool b_selected
True if this item is selected.
Definition vlc_extensions.h:320
struct extension_widget_value_t * p_next
Next value or NULL.
Definition vlc_extensions.h:321
char * psz_text
String value.
Definition vlc_extensions.h:319
Widget descriptor for extensions.
Definition vlc_extensions.h:310
int i_spin_loops
Number of loops to play (-1 = infinite, 0 = stop animation)
Definition vlc_extensions.h:337
char * psz_text
Text. May be NULL or modified by the UI.
Definition vlc_extensions.h:313
bool b_hide
Hide this widget (make it invisible)
Definition vlc_extensions.h:334
extension_widget_type_e type
Type of the widget.
Definition vlc_extensions.h:312
int i_horiz_span
Horizontal size of the object.
Definition vlc_extensions.h:330
bool b_checked
Is this entry checked.
Definition vlc_extensions.h:325
struct extension_widget_t::extension_widget_value_t * p_values
Chained list of values (Drop-down/List)
int i_column
Column in the grid.
Definition vlc_extensions.h:329
int i_width
Width hint.
Definition vlc_extensions.h:332
int i_vert_span
Vertical size of the object.
Definition vlc_extensions.h:331
bool b_kill
Destroy this widget.
Definition vlc_extensions.h:341
void * p_sys
Reserved for the extension manager.
Definition vlc_extensions.h:345
int i_row
Row in the grid.
Definition vlc_extensions.h:328
int i_height
Height hint.
Definition vlc_extensions.h:333
extension_dialog_t * p_dialog
Parent dialog.
Definition vlc_extensions.h:349
bool b_update
Update this widget.
Definition vlc_extensions.h:342
void * p_sys_intf
Reserved for the UI, but: NULL means the UI has destroyed the widget or has not created it yet.
Definition vlc_extensions.h:346
Extensions manager object.
Definition vlc_extensions.h:75
int(* pf_control)(extensions_manager_t *, int, extension_t *, va_list)
Control, see extension_Control.
Definition vlc_extensions.h:90
struct vlc_player_t * player
Definition vlc_extensions.h:80
struct vlc_object_t obj
Definition vlc_extensions.h:76
void * p_sys
Reserved for the module.
Definition vlc_extensions.h:79
module_t * p_module
Extensions manager module.
Definition vlc_extensions.h:78
struct extensions_manager_t::@223 extensions
Array of extension descriptors.
const struct vlc_extensions_manager_operations * ops
Implementation of the extension manager operations.
Definition vlc_extensions.h:97
vlc_mutex_t lock
A lock for the extensions array.
Definition vlc_extensions.h:83
Internal module descriptor.
Definition modules.h:76
Condition variable.
Definition vlc_threads.h:270
Definition vlc_extensions.h:59
int(* trigger_menu)(extensions_manager_t *, extension_t *, int)
Definition vlc_extensions.h:67
int(* activate)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:60
bool(* has_menu)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:63
int(* get_menu)(extensions_manager_t *, extension_t *, char ***, uint16_t **)
Definition vlc_extensions.h:64
bool(* trigger_only)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:65
bool(* is_activated)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:62
int(* set_input)(extensions_manager_t *, extension_t *, input_item_t *)
Definition vlc_extensions.h:68
int(* playing_changed)(extensions_manager_t *, extension_t *, int)
Definition vlc_extensions.h:69
int(* meta_changed)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:70
int(* trigger)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:66
int(* deactivate)(extensions_manager_t *, extension_t *)
Definition vlc_extensions.h:61
Mutex.
Definition vlc_threads.h:143
VLC object common members.
Definition vlc_objects.h:53
This file defines functions, structures and macros for handling arrays in vlc.
#define DECL_ARRAY(type)
Definition vlc_arrays.h:181
This file is a collection of common definitions and types.
static bool vlc_extension_GetBool(extensions_manager_t *p_mgr, extension_t *p_ext, int i_flag, bool b_default)
Helper for extension_HasMenu, extension_IsActivated... Do not use.
Definition vlc_extensions.h:142
static int extension_Control(extensions_manager_t *p_mgr, int i_control, extension_t *ext,...)
Control function for extensions.
Definition vlc_extensions.h:126
struct extensions_manager_sys_t extensions_manager_sys_t
Definition vlc_extensions.h:32
static int extension_SetInput(extensions_manager_t *p_mgr, extension_t *p_ext, input_item_t *p_item)
Trigger an entry of the extension menu.
Definition vlc_extensions.h:192
extension_dialog_event_e
User interface event types.
Definition vlc_extensions.h:226
@ EXTENSION_EVENT_CLOSE
Close the dialog: no data.
Definition vlc_extensions.h:228
@ EXTENSION_EVENT_CLICK
Click on a widget: data = widget.
Definition vlc_extensions.h:227
static int extension_TriggerMenu(extensions_manager_t *p_mgr, extension_t *p_ext, uint16_t i)
Trigger an entry of the extension menu.
Definition vlc_extensions.h:183
extension_widget_type_e
Widget types.
Definition vlc_extensions.h:295
@ EXTENSION_WIDGET_LIST
Vertical list box (of strings)
Definition vlc_extensions.h:303
@ EXTENSION_WIDGET_BUTTON
Clickable button.
Definition vlc_extensions.h:297
@ EXTENSION_WIDGET_CHECK_BOX
Checkable box with label.
Definition vlc_extensions.h:304
@ EXTENSION_WIDGET_HTML
HTML or rich text area (non editable)
Definition vlc_extensions.h:299
@ EXTENSION_WIDGET_DROPDOWN
Drop-down box.
Definition vlc_extensions.h:302
@ EXTENSION_WIDGET_TEXT_FIELD
Editable text line for user input.
Definition vlc_extensions.h:300
@ EXTENSION_WIDGET_PASSWORD
Editable password input (******)
Definition vlc_extensions.h:301
@ EXTENSION_WIDGET_SPIN_ICON
A "loading..." spinning icon.
Definition vlc_extensions.h:305
@ EXTENSION_WIDGET_IMAGE
Image label (psz_text is local URI)
Definition vlc_extensions.h:298
@ EXTENSION_WIDGET_LABEL
Text label.
Definition vlc_extensions.h:296
static int extension_DialogCommand(extension_dialog_t *p_dialog, extension_dialog_event_e event, void *data)
Send a command to an Extension dialog.
Definition vlc_extensions.h:268
@ EXTENSION_GET_MENU
arg1: extension_t*, arg2: char***, arg3: uint16_t**
Definition vlc_extensions.h:108
@ EXTENSION_PLAYING_CHANGED
arg1: extension_t*, arg2 int( playing status )
Definition vlc_extensions.h:113
@ EXTENSION_IS_ACTIVATED
arg1: extension_t*, arg2: bool*
Definition vlc_extensions.h:106
@ EXTENSION_ACTIVATE
arg1: extension_t*
Definition vlc_extensions.h:104
@ EXTENSION_HAS_MENU
arg1: extension_t*
Definition vlc_extensions.h:107
@ EXTENSION_TRIGGER
arg1: extension_t*
Definition vlc_extensions.h:110
@ EXTENSION_SET_INPUT
arg1: extension_t*, arg2 (input_item_t*)
Definition vlc_extensions.h:112
@ EXTENSION_META_CHANGED
arg1: extension_t*, arg2 (input_item_t*)
Definition vlc_extensions.h:114
@ EXTENSION_TRIGGER_MENU
arg1: extension_t*, int (uint16_t)
Definition vlc_extensions.h:111
@ EXTENSION_TRIGGER_ONLY
arg1: extension_t*, arg2: bool*
Definition vlc_extensions.h:109
@ EXTENSION_DEACTIVATE
arg1: extension_t*
Definition vlc_extensions.h:105
static int extension_GetMenu(extensions_manager_t *p_mgr, extension_t *p_ext, char ***pppsz, uint16_t **ppi)
Get this extension's sub-menu.
Definition vlc_extensions.h:174
int vlc_extension_VaControl(extensions_manager_t *p_mgr, int i_control, extension_t *ext, va_list args)
Definition extensions.c:32
static int extension_PlayingChanged(extensions_manager_t *p_mgr, extension_t *p_ext, int state)
Definition vlc_extensions.h:198
static int extension_MetaChanged(extensions_manager_t *p_mgr, extension_t *p_ext)
Definition vlc_extensions.h:205
Thread primitive declarations.