• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ eail_widget_get_widget函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中eail_widget_get_widget函数的典型用法代码示例。如果您正苦于以下问题:C++ eail_widget_get_widget函数的具体用法?C++ eail_widget_get_widget怎么用?C++ eail_widget_get_widget使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了eail_widget_get_widget函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: eail_naviframe_ref_child

/**
 * @brief Implementation AtkObject->ref_child callback
 *
 * ATK doc says:\n
 * Gets a reference to the specified accessible child of the object. The
 * accessible children are 0-based so the first accessible child is at index 0,
 * the second at index 1 and so on.
 *
 * @returns an AtkObject representing the specified accessible child of the
 * accessible.
 */
static AtkObject *
eail_naviframe_ref_child(AtkObject *obj, gint i)
{
   Eina_List *list;
   EailNaviframe *naviframe;
   EailWidget *widget;
   Evas_Object *e_object;

   g_return_val_if_fail(EAIL_IS_NAVIFRAME(obj), NULL);

   naviframe = EAIL_NAVIFRAME(obj);
   widget = EAIL_WIDGET(naviframe);

   e_object = eail_widget_get_widget(widget);

   list = elm_naviframe_items_get(e_object);
   int list_count = eina_list_count(list);
   if (i >= list_count)
     {
        eina_list_free(list);
        return NULL;
     }

   AtkObject *child = eail_naviframe_page_new(obj, i);
   atk_object_initialize(child, eina_list_nth(list, i));
   g_object_ref(child);
   naviframe->cached_pages = eina_list_append(naviframe->cached_pages, child);

   eina_list_free(list);

   return child;
}
开发者ID:radoslawjablonski,项目名称:eail,代码行数:43,代码来源:eail_naviframe.c


示例2: eail_multibuttonentry_cut_text

/**
 * @brief Cuts text content from entry to clipboard
 *
 * @param text an AtkEditableText
 * @param start_pos start position of cursor
 * @param end_pos end position of cursor
 */
static void
eail_multibuttonentry_cut_text(AtkEditableText *text,
                    gint             start_pos,
                    gint             end_pos)
{
   Evas_Object *widget;
   Evas_Object *entry;
   const char *entry_text;
   char *tmp;
   GString *s;


   widget = eail_widget_get_widget(EAIL_WIDGET(text));
   if (!widget || !elm_multibuttonentry_editable_get(widget)) return;

   entry = elm_multibuttonentry_entry_get(widget);
   entry_text = elm_entry_entry_get(entry);
   tmp = eail_get_substring(entry_text, start_pos, end_pos);
   eail_clipboard_set_text(tmp);
   g_free(tmp);

   s = g_string_new(entry_text);
   s = g_string_erase(s, start_pos, end_pos - start_pos);

   elm_entry_entry_set(entry, s->str);
   g_string_free(s, TRUE);
}
开发者ID:patrykka,项目名称:eail,代码行数:34,代码来源:eail_multibuttonentry.c


示例3: eail_button_get_image_position

/**
 * @brief Implementation of get_image_position from AtkImage interface
 *
 * @param image EailButton instance
 * @param [out] x horizontal coordinate
 * @param [out] y vertical coordinate
 * @param coord_type coord type
 */
static void
eail_button_get_image_position(AtkImage     *image,
                               gint         *x,
                               gint         *y,
                               AtkCoordType  coord_type)
{
    Evas_Object *button_image;
    Evas_Object *widget;
    AtkObject *obj;

    widget = eail_widget_get_widget(EAIL_WIDGET(image));
    if (!widget)
    {
        *x = G_MININT;
        *y = G_MININT;
        return;
    }

    button_image = elm_object_part_content_get(widget, "icon");
    if (button_image)
    {
        obj = eail_factory_get_accessible(button_image);
        atk_image_get_image_position(ATK_IMAGE(obj), x, y, coord_type);
    }
    else
    {
        *x = G_MININT;
        *y = G_MININT;
    }
}
开发者ID:patrykka,项目名称:eail,代码行数:38,代码来源:eail_button.c


示例4: eail_button_get_image_size

/**
 * @brief Implementation of get_image_size from AtkImage interface
 *
 * @param image EailButton instance
 * @param [out] width width image
 * @param [out] height height image
 */
static void
eail_button_get_image_size(AtkImage *image,
                           gint     *width,
                           gint     *height)
{
    Evas_Object *widget;
    Evas_Object *button_image;
    AtkObject *obj;

    widget = eail_widget_get_widget(EAIL_WIDGET(image));
    if (!widget)
    {
        *width = -1;
        *height = -1;
        return;
    }

    button_image = elm_object_part_content_get(widget, "icon");
    if (button_image)
    {
        obj = eail_factory_get_accessible(button_image);
        atk_image_get_image_size(ATK_IMAGE(obj), width, height);
    }
    else
    {
        *width = -1;
        *height = -1;
    }
}
开发者ID:patrykka,项目名称:eail,代码行数:36,代码来源:eail_button.c


示例5: eail_multibuttonentry_ref_state_set

/**
 * @brief Gets obj state set
 *
 * The caller must unreference it when it is no longer needed
 *
 * @param obj an AtkObject
 * @return obj state set
 */
static AtkStateSet *
eail_multibuttonentry_ref_state_set(AtkObject *obj)
{
   AtkStateSet *state_set;
   Evas_Object *widget;

   g_return_val_if_fail(EAIL_MULTIBUTTONENTRY(obj), NULL);

   widget = eail_widget_get_widget(EAIL_WIDGET(obj));
   state_set = ATK_OBJECT_CLASS(eail_multibuttonentry_parent_class)->ref_state_set(obj);

   if (!widget) return state_set;

   if (elm_multibuttonentry_expanded_get(widget))
     {
        atk_state_set_add_state(state_set, ATK_STATE_EXPANDED);

        if (elm_multibuttonentry_editable_get(widget))
            atk_state_set_add_state(state_set, ATK_STATE_EDITABLE);
     }
   else
     {
        atk_state_set_add_state(state_set, ATK_STATE_DEFAULT);
     }

   return state_set;
}
开发者ID:patrykka,项目名称:eail,代码行数:35,代码来源:eail_multibuttonentry.c


示例6: eail_naviframe_initialize

/**
 * @brief Initializer for AtkObjectClass
 *
 * @param obj an AtkObject
 * @param data initialization data
 */
static void
eail_naviframe_initialize(AtkObject *obj, gpointer data)
{
   Evas_Object *nested_widget = NULL;
   EailNaviframe *naviframe_obj = NULL;
   ATK_OBJECT_CLASS(eail_naviframe_parent_class)->initialize(obj, data);

   obj->role = ATK_ROLE_PAGE_TAB_LIST;
   g_return_if_fail(EAIL_IS_WIDGET(obj));

   nested_widget = eail_widget_get_widget(EAIL_WIDGET(obj));
   if (!nested_widget)
     {
        ERR("No evas object inside EailWidget was found");
        return;
     }

   evas_object_smart_callback_add(nested_widget, "transition,finished",
                                _eail_naviframe_handle_page_changed_event, obj);

   eail_naviframe_actions_init(EAIL_ACTION_WIDGET(obj));

   naviframe_obj = EAIL_NAVIFRAME(obj);
   /* storing last numbers of children to be for checking if children-changed
    * signal has to be propagated */
   naviframe_obj->child_count_last = eail_naviframe_n_children_get(obj);
}
开发者ID:patrykka,项目名称:eail,代码行数:33,代码来源:eail_naviframe.c


示例7: eail_multibuttonentry_get_items

/**
 * @brief Gets multibuttonentry items list
 *
 * @param multibuttonentry an EailMultibuttonentry
 * @return multibuttonentry items list
 * */
static const Eina_List *
eail_multibuttonentry_get_items(EailMultibuttonentry *multibuttonentry)
{
   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(multibuttonentry));
   if (!widget) return NULL;

   return elm_multibuttonentry_items_get(widget);
}
开发者ID:patrykka,项目名称:eail,代码行数:14,代码来源:eail_multibuttonentry.c


示例8: eail_gengrid_items_get

/**
 * @brief Get list of created widgets
 *
 * @param gengrid EailGengrid instance
 *
 * @returns list of widgets elm_gengrid holds
 */
static Eina_List *
eail_gengrid_items_get(EailGengrid *gengrid)
{
   g_return_val_if_fail(EAIL_IS_WIDGET(gengrid), NULL);

   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(gengrid));

   return elm_gengrid_realized_items_get(widget);
}
开发者ID:patrykka,项目名称:eail,代码行数:16,代码来源:eail_gengrid.c


示例9: eail_segment_control_get_n_children

/**
 * @brief Implementation AtkObject->get_n_children callback
 *
 * ATK doc says:\n
 * Gets the number of accessible children of the accessible.
 *
 * @param obj an AtkObject
 *
 * @returns an integer representing the number of accessible children of
 * the accessible
 */
static gint
eail_segment_control_get_n_children(AtkObject *obj)
{
   gint n_items;

   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(obj));
   n_items = elm_segment_control_item_count_get(widget);

   return n_items;
}
开发者ID:radoslawjablonski,项目名称:eail,代码行数:21,代码来源:eail_segment_control.c


示例10: eail_index_get_index_items

/**
 * @brief gets list of Elm_Object_Item* that is contained in index widget
 *
 * @param obj and EailIndex AtkObject
 *
 * @returns const Eina_List * with Elm_Object_Item* for every index
 */
static const Eina_List *
eail_index_get_index_items(AtkObject *obj) {
   Evas_Object *index_widget = NULL;

   index_widget = eail_widget_get_widget(EAIL_WIDGET(obj));
   g_return_val_if_fail(index_widget, NULL);

   ELM_INDEX_DATA_GET(index_widget, index_sd);
   g_return_val_if_fail(index_sd, NULL);

   return index_sd->items;
}
开发者ID:radoslawjablonski,项目名称:eail,代码行数:19,代码来源:eail_index.c


示例11: _eail_photocam_action_click

/**
 * @brief Click action callback
 *
 * @param action an AtkAction
 * @param data data passed to callback
 * @return TRUE on success, FALSE otherwise
 */
static gboolean
_eail_photocam_action_click(AtkAction *action, void *data)
{
   Evas_Object *widget;

   g_return_val_if_fail(EAIL_IS_PHOTOCAM(action), FALSE);
   widget = eail_widget_get_widget(EAIL_WIDGET(action));
   if (!widget) return FALSE;

   evas_object_smart_callback_call(widget, "clicked", NULL);
   return TRUE;
}
开发者ID:patrykka,项目名称:eail,代码行数:19,代码来源:eail_photocam.c


示例12: eail_grid_children_get

/**
 * @brief Implementation of eail_widget_get_widget_children callback from
 * EailWidget
 *
 * @param widget an EailWidget
 *
 * @returns Eina_List filled with Evas_Object* objects contained in grid widget
 */
static Eina_List*
eail_grid_children_get(EailWidget *widget)
{
   Evas_Object *obj;
   Eina_List *list = NULL;

   obj = eail_widget_get_widget(widget);
   if (obj)
     list = elm_grid_children_get(obj);

   return list;
}
开发者ID:patrykka,项目名称:eail,代码行数:20,代码来源:eail_grid.c


示例13: _action_scroll_up

/**
 * @brief Scrollup action callback
 *
 * @param action an AtkAction
 * @param data additional callback data
 * @returns TRUE on success, FALSE otherwise
 */
static gboolean
_action_scroll_up(AtkAction *action,
                  void *data)
{
   Evas_Object *widget;

   g_return_val_if_fail(EAIL_IS_SCROLLABLE_WIDGET(action), FALSE);

   widget = eail_widget_get_widget(EAIL_WIDGET(action));
   _eail_scrollable_handle_scroll_event(action, widget, NULL);
   return eail_action_scroll_up(widget, NULL);
}
开发者ID:patrykka,项目名称:eail,代码行数:19,代码来源:eail_scrollable_widget.c


示例14: _eail_get_popup_widget_from_atkobj

/**
 * @brief Helper function to getting "elm_popup" Evas_Object* from Atk EailPopup
 *
 * @returns nested "elm_popup" widget
 */
static Evas_Object *
_eail_get_popup_widget_from_atkobj(AtkObject *obj)
{
    Evas_Object *popup_widget = NULL;
    popup_widget = eail_widget_get_widget(EAIL_WIDGET(obj));
    if (!popup_widget)
    {
        ERR("No widget found for notification object!");
        return NULL;
    }

    return popup_widget;
}
开发者ID:radoslawjablonski,项目名称:eail,代码行数:18,代码来源:eail_popup.c


示例15: eail_slider_initialize

/**
 * @brief EailSlider object initialization
 *
 * @param obj EailSlider object
 * @param data user set additional initialization data
 */
static void
eail_slider_initialize(AtkObject *obj, gpointer data)
{
   Evas_Object *nested_widget = NULL;
   ATK_OBJECT_CLASS(eail_slider_parent_class)->initialize(obj, data);

   obj->role = ATK_ROLE_SLIDER;
   g_return_if_fail(EAIL_IS_WIDGET(obj));

   nested_widget = eail_widget_get_widget(EAIL_WIDGET(obj));
   evas_object_smart_callback_add(nested_widget, "changed",
                                  _eail_slider_handle_changed_event, obj);
}
开发者ID:patrykka,项目名称:eail,代码行数:19,代码来源:eail_slider.c


示例16: eail_button_get_character_at_offset

/**
 * @brief Gets the character at offset
 *
 * @param text AtkText instance
 * @param offset character offset
 * @returns char representing the character at offset
 */
static gunichar
eail_button_get_character_at_offset(AtkText    *text,
                                    gint        offset)
{
   gunichar character = '\0';
   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(text));

   if (widget)
     character = g_utf8_get_char(
         g_utf8_offset_to_pointer(elm_object_text_get(widget), offset));

   return character;
}
开发者ID:mknapinski,项目名称:eail,代码行数:20,代码来源:eail_button.c


示例17: eail_button_get_text

/**
 * @brief Gets text bounded by start_offset and end_offset
 *
 * Use g_free() to free the returned string.
 *
 * @param text AtkText instance
 * @param start_offset start position
 * @param end_offset end position, -1 for the end of the string
 *
 * @return string containing the text from start_offset up to,
 * but not including end_offset
 */
static gchar*
eail_button_get_text(AtkText   *text,
                     gint       start_offset,
                     gint       end_offset)
{
   gchar *string = NULL;
   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(text));

   if (widget)
     string = (gchar *)elm_object_text_get(widget);

   return eail_get_substring(string, start_offset, end_offset);
}
开发者ID:mknapinski,项目名称:eail,代码行数:25,代码来源:eail_button.c


示例18: eail_panel_action_toggle

/**
 * @brief Inits Action interface for PANEL
 *
 * @param action an AtkAction
 * @param data data passed to callback
 * @returns TRUE on success, FALSE otherwise
 */
static gboolean
eail_panel_action_toggle(AtkAction *action, void *data)
{
   Evas_Object *widget;

   g_return_val_if_fail(EAIL_IS_PANEL(action), FALSE);

   widget = eail_widget_get_widget(EAIL_WIDGET(action));
   if (!widget) return FALSE;

   elm_panel_toggle(widget);

   return TRUE;
}
开发者ID:patrykka,项目名称:eail,代码行数:21,代码来源:eail_panel.c


示例19: eail_photo_size_get

/**
 * @brief Gets the image size
 *
 * @param image AtkImage instance
 * @param [out] width photo width or -1 if value cannot be obtained
 * @param [out] height photo height or -1 if value cannot be obtained
 */
static void
eail_photo_size_get(AtkImage *image, gint *width, gint *height)
{
   g_return_if_fail(ATK_IS_IMAGE(image));

   Evas_Object *widget = eail_widget_get_widget(EAIL_WIDGET(image));
   if (!widget)
     {
        *width = -1;
        *height = -1;
        return;
     }
   evas_object_geometry_get(widget, NULL, NULL, width, height);
}
开发者ID:mknapinski,项目名称:eail,代码行数:21,代码来源:eail_photo.c


示例20: eail_popup_get_name

/**
 * @brief Gets name of EailItem
 *
 * Implementation of AtkObject->get_name callback
 *
 * ATK doc says:\n
 * Gets the accessible name of the accessible.
 *
 * @returns a character string representing the accessible description of
 * the accessible.
 */
static const gchar *
eail_popup_get_name(AtkObject *obj)
{
    Evas_Object *popup_widget = NULL;

    popup_widget = eail_widget_get_widget(EAIL_WIDGET(obj));
    if (!popup_widget)
    {
        ERR("No widget found for notification object!");
        return NULL;
    }

    return elm_object_part_text_get(popup_widget, "title,text");
}
开发者ID:radoslawjablonski,项目名称:eail,代码行数:25,代码来源:eail_popup.c



注:本文中的eail_widget_get_widget函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ ealloc函数代码示例发布时间:2022-05-30
下一篇:
C++ e_wsle函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap