Ewl_IO_Manager: An input manager
Detailed Description
Defines a class for handling reading various input and creating the correct widgets.
Tutorial
Data Structures | |
struct | Ewl_IO_Manager_Plugin |
Provides the base structure for IO Manager plugins. More... | |
Typedefs | |
typedef struct Ewl_IO_Manager_Plugin | Ewl_IO_Manager_Plugin |
Functions | |
const char * | ewl_io_manager_extension_icon_name_get (const char *ext) |
Retrieve the icon name for the given extension or NULL if none found. | |
int | ewl_io_manager_init (void) |
Initializes the IO manager system. | |
const char * | ewl_io_manager_mime_type_icon_name_get (const char *mime) |
Retrives the icon name for the given mime type or NULL if none found. | |
void | ewl_io_manager_shutdown (void) |
Shuts down the io manager system. | |
Ewl_Widget * | ewl_io_manager_string_read (const char *string, const char *mime) |
Reads the given string and interprets it as the given mime type. | |
int | ewl_io_manager_string_write (Ewl_Widget *data, char **string, const char *mime) |
Writes the given data into the given string pointer. | |
const char * | ewl_io_manager_uri_mime_type_get (const char *uri) |
Retrives the mime type for the given URI or NULL on error. | |
Ewl_Widget * | ewl_io_manager_uri_read (const char *uri) |
Creates a widget to display the URI contents. Returns NULL on error. | |
int | ewl_io_manager_uri_write (Ewl_Widget *data, const char *uri, const char *mime) |
Writes the given data out to uri as mime type mime. |
Typedef Documentation
typedef struct Ewl_IO_Manager_Plugin Ewl_IO_Manager_Plugin |
Function Documentation
const char* ewl_io_manager_extension_icon_name_get | ( | const char * | ext | ) |
Retrieve the icon name for the given extension or NULL if none found.
- Parameters:
-
ext,: The extension to look up
- Returns:
- Returns the icon name for the given extension or NULL if none found
References DCHECK_PARAM_PTR_RET, DENTER_FUNCTION, DLEVEL_STABLE, and DRETURN_PTR.
Referenced by ewl_filelist_stock_icon_get().
int ewl_io_manager_init | ( | void | ) |
Initializes the IO manager system.
- Returns:
- Returns TRUE on successful initialization, FALSE otherwise
References DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_INT, EWL_ICON_AUDIO_X_GENERIC, EWL_ICON_IMAGE_X_GENERIC, EWL_ICON_TEXT_HTML, EWL_ICON_TEXT_X_SCRIPT, and EWL_ICON_VIDEO_X_GENERIC.
Referenced by ewl_init().
const char* ewl_io_manager_mime_type_icon_name_get | ( | const char * | mime | ) |
Retrives the icon name for the given mime type or NULL if none found.
- Parameters:
-
mime,: The mime type to get the icon for
- Returns:
- Returns the icon name for the given mime type or NULL if none found
References DCHECK_PARAM_PTR_RET, DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_PTR, and DWARNING.
void ewl_io_manager_shutdown | ( | void | ) |
Shuts down the io manager system.
- Returns:
- Returns no value
References DENTER_FUNCTION, DLEAVE_FUNCTION, DLEVEL_STABLE, and IF_FREE_HASH.
Referenced by ewl_init().
Ewl_Widget* ewl_io_manager_string_read | ( | const char * | string, | |
const char * | mime | |||
) |
Reads the given string and interprets it as the given mime type.
- Parameters:
-
string,: The string to read mime,: The mime type to interpret the string as
- Returns:
- Returns a widget representing the string in the given mime type
References DCHECK_PARAM_PTR_RET, DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_PTR, DWARNING, and Ewl_IO_Manager_Plugin::string_read.
int ewl_io_manager_string_write | ( | Ewl_Widget * | data, | |
char ** | string, | |||
const char * | mime | |||
) |
Writes the given data into the given string pointer.
- Parameters:
-
data,: The data to write string,: Where to write mime,: The mime type to write as
- Returns:
- Returns TRUE if the write is successful, FALSE otherwise
References DCHECK_PARAM_PTR_RET, DCHECK_TYPE_RET, DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_INT, DWARNING, EWL_WIDGET_TYPE, and Ewl_IO_Manager_Plugin::string_write.
const char* ewl_io_manager_uri_mime_type_get | ( | const char * | uri | ) |
Retrives the mime type for the given URI or NULL on error.
- Parameters:
-
uri,: The URI to look up the mime type for
- Returns:
- Returns the mime type for the given URI or NULL on error
References DCHECK_PARAM_PTR_RET, DENTER_FUNCTION, DLEVEL_STABLE, and DRETURN_PTR.
Referenced by ewl_io_manager_uri_read().
Ewl_Widget* ewl_io_manager_uri_read | ( | const char * | uri | ) |
Creates a widget to display the URI contents. Returns NULL on error.
- Parameters:
-
uri,: The URI to read
- Returns:
- Returns a widget displaying the URI contents or NULL on error
References DCHECK_PARAM_PTR_RET, DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_PTR, DWARNING, ewl_io_manager_uri_mime_type_get(), and Ewl_IO_Manager_Plugin::uri_read.
int ewl_io_manager_uri_write | ( | Ewl_Widget * | data, | |
const char * | uri, | |||
const char * | mime | |||
) |
Writes the given data out to uri as mime type mime.
- Parameters:
-
data,: The data to write uri,: The URI to write the data too mime,: The mime type to write the data out as
- Returns:
- Returns TRUE on success, FALSE otherwise
References DCHECK_PARAM_PTR_RET, DCHECK_TYPE_RET, DENTER_FUNCTION, DLEVEL_STABLE, DRETURN_INT, DWARNING, EWL_WIDGET_TYPE, and Ewl_IO_Manager_Plugin::uri_write.