User interaction dialog APIs. More...

Go to the source code of this file.
Data Structures | |
| struct | dialog_fatal_t |
| A fatal error dialog. More... | |
| struct | dialog_question_t |
| A question dialog. More... | |
| struct | dialog_progress_bar_t |
Defines | |
| #define | dialog_Fatal(o, t,...) dialog_Fatal(VLC_OBJECT(o), t, __VA_ARGS__) |
| #define | dialog_FatalWait(o, t,...) dialog_FatalWait(VLC_OBJECT(o), t, __VA_ARGS__) |
| #define | dialog_Login(o, u, p, t,...) dialog_Login(VLC_OBJECT(o), u, p, t, __VA_ARGS__) |
| #define | dialog_Question(o, t, m, y, n, c) dialog_Question(VLC_OBJECT(o), t, m, y, n, c) |
| #define | dialog_ProgressCreate(o, t, m, c) dialog_ProgressCreate(VLC_OBJECT(o), t, m, c) |
| #define | dialog_Register(o) dialog_Register(VLC_OBJECT(o)) |
| #define | dialog_Unregister(o) dialog_Unregister(VLC_OBJECT(o)) |
Typedefs | |
| typedef struct dialog_fatal_t | dialog_fatal_t |
| A fatal error dialog. | |
| typedef struct dialog_question_t | dialog_question_t |
| A question dialog. | |
| typedef struct dialog_progress_bar_t | dialog_progress_bar_t |
Functions | |
| VLC_API void | dialog_VFatal (vlc_object_t *, bool, const char *, const char *, va_list) |
| Sends an error message through the user interface (if any). | |
| static | VLC_FORMAT (3, 4) void dialog_Fatal(vlc_object_t *obj |
| va_start (ap, fmt) | |
| dialog_VFatal (obj, false, title, fmt, ap) | |
| va_end (ap) | |
| VLC_API void | dialog_Login (vlc_object_t *, char **, char **, const char *, const char *,...) VLC_FORMAT(5 |
| VLC_API int | dialog_Question (vlc_object_t *, const char *, const char *, const char *, const char *, const char *) |
| Asks a total (Yes/No/Cancel) question through the user interface. | |
| VLC_API dialog_progress_bar_t * | dialog_ProgressCreate (vlc_object_t *, const char *, const char *, const char *) VLC_USED |
| Creates a progress bar dialog. | |
| VLC_API void | dialog_ProgressDestroy (dialog_progress_bar_t *) |
| VLC_API void | dialog_ProgressSet (dialog_progress_bar_t *, const char *, float) |
| VLC_API bool | dialog_ProgressCancelled (dialog_progress_bar_t *) |
| VLC_API int | dialog_Register (vlc_object_t *) |
| Registers an object as the dialog provider. | |
| VLC_API int | dialog_Unregister (vlc_object_t *) |
| Unregisters the dialog provider. | |
Variables | |
| static const char * | title |
| static const char const char * | fmt |
| static const char const char va_list | ap |
User interaction dialog APIs.
| #define dialog_Fatal | ( | o, | ||
| t, | ||||
| ... | ||||
| ) | dialog_Fatal(VLC_OBJECT(o), t, __VA_ARGS__) |
Referenced by aout_FiltersCreatePipeline(), decoder_New(), DecoderUnsupportedCodec(), input_DecoderSetCcState(), and InputSourceInit().
| #define dialog_FatalWait | ( | o, | ||
| t, | ||||
| ... | ||||
| ) | dialog_FatalWait(VLC_OBJECT(o), t, __VA_ARGS__) |
| #define dialog_Login | ( | o, | ||
| u, | ||||
| p, | ||||
| t, | ||||
| ... | ||||
| ) | dialog_Login(VLC_OBJECT(o), u, p, t, __VA_ARGS__) |
| #define dialog_ProgressCreate | ( | o, | ||
| t, | ||||
| m, | ||||
| c | ||||
| ) | dialog_ProgressCreate(VLC_OBJECT(o), t, m, c) |
| #define dialog_Question | ( | o, | ||
| t, | ||||
| m, | ||||
| y, | ||||
| n, | ||||
| c | ||||
| ) | dialog_Question(VLC_OBJECT(o), t, m, y, n, c) |
| #define dialog_Register | ( | o | ) | dialog_Register(VLC_OBJECT(o)) |
| #define dialog_Unregister | ( | o | ) | dialog_Unregister(VLC_OBJECT(o)) |
| typedef struct dialog_fatal_t dialog_fatal_t |
A fatal error dialog.
No response expected from the user.
| typedef struct dialog_progress_bar_t dialog_progress_bar_t |
| typedef struct dialog_question_t dialog_question_t |
A question dialog.
| VLC_API void dialog_Login | ( | vlc_object_t * | , | |
| char ** | , | |||
| char ** | , | |||
| const char * | , | |||
| const char * | , | |||
| ... | ||||
| ) |
| VLC_API bool dialog_ProgressCancelled | ( | dialog_progress_bar_t * | ) |
References dialog_progress_bar_t::p_sys, and dialog_progress_bar_t::pf_check.
| VLC_API dialog_progress_bar_t* dialog_ProgressCreate | ( | vlc_object_t * | , | |
| const char * | , | |||
| const char * | , | |||
| const char * | ||||
| ) |
Creates a progress bar dialog.
References dialog_progress_bar_t::cancel, dialog_GetProvider(), dialog_progress_bar_t::message, OBJECT_FLAGS_NOINTERACT, dialog_progress_bar_t::pf_check, dialog_progress_bar_t::pf_destroy, dialog_progress_bar_t::pf_update, dialog_progress_bar_t::title, var_SetAddress, and vlc_object_release.
| VLC_API void dialog_ProgressDestroy | ( | dialog_progress_bar_t * | ) |
References dialog_progress_bar_t::p_sys, and dialog_progress_bar_t::pf_destroy.
| VLC_API void dialog_ProgressSet | ( | dialog_progress_bar_t * | , | |
| const char * | , | |||
| float | ||||
| ) |
References dialog_progress_bar_t::p_sys, and dialog_progress_bar_t::pf_update.
| VLC_API int dialog_Question | ( | vlc_object_t * | obj, | |
| const char * | title, | |||
| const char * | text, | |||
| const char * | yes, | |||
| const char * | no, | |||
| const char * | cancel | |||
| ) |
Asks a total (Yes/No/Cancel) question through the user interface.
| obj | VLC object emitting the question | |
| title | dialog box title | |
| text | dialog box text | |
| yes | first choice/button text | |
| no | second choice/button text | |
| cancel | third answer/button text, or NULL if no third option |
References dialog_question_t::answer, dialog_GetProvider(), OBJECT_FLAGS_NOINTERACT, var_SetAddress, and vlc_object_release.
| VLC_API int dialog_Register | ( | vlc_object_t * | obj | ) |
Registers an object as the dialog provider.
It is assumed that the appropriate variable callbacks are already registered.
References libvlc_priv(), libvlc_priv_t::p_dialog_provider, provider_lock, vlc_mutex_lock(), and vlc_mutex_unlock().
| VLC_API int dialog_Unregister | ( | vlc_object_t * | obj | ) |
Unregisters the dialog provider.
Note that unless you have unregistered the callbacks already, the provider might still be in use by other threads. Also, you need to cancel all pending dialogs yourself.
References libvlc_priv(), libvlc_priv_t::p_dialog_provider, provider_lock, vlc_mutex_lock(), and vlc_mutex_unlock().
| VLC_API void dialog_VFatal | ( | vlc_object_t * | obj, | |
| bool | modal, | |||
| const char * | title, | |||
| const char * | fmt, | |||
| va_list | ap | |||
| ) |
Sends an error message through the user interface (if any).
| obj | the VLC object emitting the error | |
| modal | whether to wait for user to acknowledge the error before returning control to the caller | |
| title | title of the error dialog | |
| fmt | format string for the error message | |
| ap | parameters list for the formatted error message |
References dialog_GetProvider(), msg_Err, msg_GenericVa, OBJECT_FLAGS_NOINTERACT, text, var_SetAddress, vasprintf(), VLC_MSG_ERR, and vlc_object_release.
| va_end | ( | ap | ) |
Referenced by __ml_Control(), __ml_Find(), __ml_GetInt(), __ml_GetPsz(), access_Control(), config_Write(), demux_Control(), dialog_Login(), es_out_Control(), extension_Control(), httpd_MsgAdd(), info_category_AddInfo(), input_Control(), input_item_AddInfo(), InputItemAddInfo(), net_Printf(), osd_Message(), playlist_Control(), playlist_ServicesDiscoveryControl(), sdp_AddAttribute(), sout_AccessOutControl(), sout_MuxControl(), sql_Printf(), stream_Control(), us_asprintf(), utf8_fprintf(), vlc_control_cancel(), vlc_Log(), vlc_module_load(), vlc_module_unload(), vlc_open(), vlc_openat(), vlc_plugin_setter(), vlc_vaLog(), vlm_Control(), vlm_ControlInternal(), vod_MediaControl(), vout_display_Control(), vout_display_SendEvent(), vout_OSDMessage(), vout_window_Control(), and vsdp_AddAttribute().
Referenced by __ml_Control(), __ml_Find(), __ml_GetInt(), __ml_GetPsz(), access_Control(), config_Write(), demux_Control(), dialog_Login(), es_out_Control(), extension_Control(), httpd_MsgAdd(), info_category_AddInfo(), input_Control(), input_item_AddInfo(), InputItemAddInfo(), net_Printf(), osd_Message(), playlist_Control(), playlist_ServicesDiscoveryControl(), sdp_AddAttribute(), sout_AccessOutControl(), sout_MuxControl(), sql_Printf(), stream_Control(), us_asprintf(), utf8_fprintf(), vlc_control_cancel(), vlc_Log(), vlc_module_load(), vlc_module_unload(), vlc_open(), vlc_openat(), vlc_plugin_setter(), vlm_Control(), vlm_ControlInternal(), vod_MediaControl(), vout_display_Control(), vout_display_SendEvent(), vout_OSDMessage(), and vout_window_Control().
| static VLC_FORMAT | ( | 3 | , | |
| 4 | ||||
| ) | [inline, static] |
| const char const char va_list ap |
| static const char const char * fmt |
Referenced by EsOutSend(), ImageFilter(), input_DecoderSetCcState(), osd_ShowTextAbsolute(), OSDEpgUpdate(), OSDRegion(), OSDTextUpdate(), OSDWidgetUpdate(), picture_New(), picture_NewFromResource(), spu_new_video_buffer(), VideoBufferNew(), vout_ManageDisplay(), vout_new_buffer(), vout_OSDEpgSlider(), vout_OSDEpgText(), and VoutSaveSnapshot().
| static const char * title |
1.7.1