diff options
Diffstat (limited to 'src/lib/elm_plug.h')
-rw-r--r-- | src/lib/elm_plug.h | 98 |
1 files changed, 74 insertions, 24 deletions
diff --git a/src/lib/elm_plug.h b/src/lib/elm_plug.h index 17ba2962f..88ea23a85 100644 --- a/src/lib/elm_plug.h +++ b/src/lib/elm_plug.h @@ -1,42 +1,92 @@ /** * @defgroup Plug Plug - * @ingroup Elementary + * @ingroup elm_widget_group * * @image html plug_inheritance_tree.png * @image latex plug_inheritance_tree.eps * - * An object that allows one to show an image which other process created. - * It can be used anywhere like any other elementary widget. + * @brief An object that allows one to show an image which the other process created. + * It can be used anywhere like any other elementary widget. * - * This widget emits the following signals: - * @li "clicked": the user clicked the image (press/release). The @c - * event parameter of the callback will be @c NULL. - * @li "image,deleted": the server side was deleted. The @c event - * parameter of the callback will be @c NULL. - * @li "image,resized": the server side was resized. The @c event parameter of - * the callback will be @c Evas_Coord_Size (two integers). + * @{ + */ + +/** + * @typedef Elm_Plug_Message * - * @note the event "image,resized" will be sent whenever the server - * resized its image and this @b always happen on the first - * time. Then it can be used to track when the server-side image - * is fully known (client connected to server, retrieved its - * image buffer through shared memory and resized the evas - * object). + * @brief The structure type holding the message + * which elm plug received from ecore evas. * */ +struct _Elm_Plug_Message +{ + int msg_domain; + int msg_id; + void *data; + int size; +}; +typedef struct _Elm_Plug_Message Elm_Plug_Message; /** - * @addtogroup Plug - * @{ + * @brief Adds a new plug image to the parent. + * + * @since_tizen 2.3 + * + * @param[in] parent The parent object + * @return The new plug image object, otherwise @c NULL if it cannot be created + */ +EAPI Evas_Object *elm_plug_add(Evas_Object *parent); + +/** + * @brief Connects a plug widget to the service provided by the socket image. + * + * @since_tizen 2.3 + * + * @param[in] obj The Evas_Object where the new image object lives + * @param[in] svcname The service name to connect to the set up by the socket + * @param[in] svcnum The service number to connect to (set up by socket) + * @param[in] svcsys The boolean to set if the service is a system one or not (set up by socket) + * @return (@c EINA_TRUE = success, @c EINA_FALSE = error) + */ +EAPI Eina_Bool elm_plug_connect(Evas_Object *obj, const char *svcname, int svcnum, Eina_Bool svcsys); + +/** + * @brief Gets the basic Evas_Image object from this object (widget). + * + * @details This function allows one to get the underlying @c Evas_Object of type + * Image from this elementary widget. It can be useful to do things like getting + * the pixel data, saving the image to a file, etc. + * + * @since_tizen 2.3 + * + * @remarks Be careful to not manipulate it, as it is under the control of + * elementary. + * + * @param[in] obj The image object to get the inlined image from + * @return The inlined image object, otherwise @c NULL if none exist + */ +EAPI Evas_Object *elm_plug_image_object_get(const Evas_Object *obj); + +/** + * @internal + * @remarks Tizen only feature + * + * @brief Sends a message to the plug widget's socket. + * + * @since 1.8.0 + * + * @remarks Support for this depends on the underlying windowing system. + * + * @param[in] obj The plug object to send a message to + * @param[in] msg_domain The domain of the message + * @param[in] msg_id The ID of the message + * @param[in] data The data of the message + * @param[in] size The size of the message data + * */ +EAPI Eina_Bool elm_plug_msg_send(Evas_Object *obj, int msg_domain, int msg_id, void *data, int size); -#ifdef EFL_EO_API_SUPPORT -#include "elm_plug_eo.h" -#endif -#ifndef EFL_NOLEGACY_API_SUPPORT -#include "elm_plug_legacy.h" -#endif /** * @} */ |