![]() |
HBBTV
22.11.0
|
Hbbtv netscape plugin utilities. More...
#include <stdlib.h>#include <string.h>#include <stdio.h>#include <ctype.h>#include "techtype.h"#include "dbgfuncs.h"#include "hbbtv_js.h"#include "npapi_utils.h"#include "plugin.h"#include "hz_debug.h"Classes | |
| struct | S_JS_CALLBACK_PARAMS |
Functions | |
| void | NP_UtilsInit (void) |
| void | NP_UtilsArrayToResult (NPP instance, U32BIT *array, U32BIT num_elements, NPVariant *result) |
| void | NP_UtilsStringToResult (S_HBBTV_STRING str, NPVariant *result) |
| void | NP_UtilsHbbtvStringToResult (void *hbbtv_string, NPVariant *result) |
| bool | NP_UtilsStringIsNumeric (char *in_string) |
| BOOLEAN | NP_UtilsGetU32BIT (const NPVariant *input, U32BIT *output) |
| Extracts a number from an NPVariant and saves it (with casting) into the U32BIT pointed by output. This function checks whether the NPVariant contains an uint32_t or a double. More... | |
| S_OBJECT_DATA * | NP_UtilsFindObject (S_OBJECT_DATA **list, void *handle) |
| NPObject * | NP_UtilsAddEventListener (S_PLUGIN *plugin, const NPVariant *value, U32BIT event_type) |
| Adds a new event lister to an object. More... | |
| U32BIT | NP_UtilsRemoveEventListener (S_PLUGIN *plugin, NPObject *handler) |
| Remove an event lister from an object. More... | |
| void | NP_UtilsFreeAllEventListeners (S_PLUGIN *plugin) |
| Free all event handlers for an object. More... | |
| void | NP_UtilsAsyncCallback (S_PLUGIN **plugin_list, void *handle, U32BIT event_type, NPVariant *args, uint32_t num_args) |
| Call browser's pluginthreadasynccall to execute JS callback function. More... | |
| BOOLEAN | NP_UtilsResolveUrl (NPP instance, S_HBBTV_STRING *uri) |
| Resolve URL, convert to full path URL, if needed. More... | |
Hbbtv netscape plugin utilities.
| NPObject* NP_UtilsAddEventListener | ( | S_PLUGIN * | plugin, |
| const NPVariant * | value, | ||
| U32BIT | event_type | ||
| ) |
Adds a new event lister to an object.
| input | - Pointer to plugin object |
| input | - NPVariant reference to new event handler |
| input | - Object-specific event-type id |
| void NP_UtilsAsyncCallback | ( | S_PLUGIN ** | plugin_list, |
| void * | handle, | ||
| U32BIT | event_type, | ||
| NPVariant * | args, | ||
| uint32_t | num_args | ||
| ) |
Call browser's pluginthreadasynccall to execute JS callback function.
| input | - NPP plugin instance reference |
| input | - NP object of JS Callback function to invoke |
| input | - Array of arguments |
| input | - Number of arguments |
| void NP_UtilsFreeAllEventListeners | ( | S_PLUGIN * | plugin | ) |
Free all event handlers for an object.
| input | - Pointer to head of handler list to be freed |
| BOOLEAN NP_UtilsGetU32BIT | ( | const NPVariant * | input, |
| U32BIT * | output | ||
| ) |
Extracts a number from an NPVariant and saves it (with casting) into the U32BIT pointed by output. This function checks whether the NPVariant contains an uint32_t or a double.
| input | - NPVariant variable containing the number |
| output | - pointer to an U32BIT variable where to store the result |
Remove an event lister from an object.
| input | - Pointer to head of handler list |
| input | - NPObject reference of event handler to be removed |
| BOOLEAN NP_UtilsResolveUrl | ( | NPP | instance, |
| S_HBBTV_STRING * | uri | ||
| ) |
Resolve URL, convert to full path URL, if needed.
| input | - NPP plugin instance reference |
| input/output | - URL (input relative or full, output is full path) |
1.8.11