efl: make all _class_get() functions const

please note, not the return type, but the function.
When appending __attribute__((const)) to a function, the compiler is
told that its enough to call this function once in a function.

This is quite often happening when we are efl_data_scope_get and
efl_super in a function that is different from a implemented function.

The compiler now starts to remove the calls that aggressivly that we
need to ensure that these calls are not removed, which means, the static
function calls, and the eo init are now checking the return value of
these functions, to ensure that they are called.

Please note that you now have to be carefull when your app calls
eo_shutdown, if it does so, you *must* call it at the end of a function,
or never call class_get after that anymore.

Overall this improves elm test runs 0.1s which is fair i guess, the main
thing that is faster is textrendering, where is also the point where
this is the most beneficial.

Please note, this replaces 42 occurences of double _class_get() ... THAT
is a sign!

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Reviewed-by: Daniel Kolesa <daniel@octaforge.org>
Differential Revision: https://phab.enlightenment.org/D12057
This commit is contained in:
Marcel Hollerbach 2020-07-16 12:39:23 +02:00
parent a9710f54c1
commit a931e41823
131 changed files with 155 additions and 142 deletions

View File

@ -225,7 +225,7 @@ eo_gen_header_gen(const Eolian_State *state, const Eolian_Class *cl,
eina_strbuf_append_printf(buf, "#define %s %s()\n\n", mname, gname);
eina_stringshare_del(mname);
eina_strbuf_append_printf(buf, "EWAPI const Efl_Class *%s(void);\n", gname);
eina_strbuf_append_printf(buf, "EWAPI const Efl_Class *%s(void) EINA_CONST;\n", gname);
eina_stringshare_del(gname);
/* method section */

View File

@ -472,7 +472,7 @@ _gen_reflect_set(Eina_Strbuf *buf, const char *cnamel,
}
static void
_emit_class_function(Eina_Strbuf *buf, const Eolian_Function *fid, const char *rtpn, Eina_Strbuf *params_full,
_emit_class_function(Eina_Strbuf *buf, const Eolian_Function *fid, const Eolian_Function_Type ftype, const Eolian_Type *rtp, const char *rtpn, Eina_Strbuf *params_full,
const char *ocnamel, const char *func_suffix, Eina_Strbuf *params, const char *function_name)
{
eina_strbuf_append(buf, "EOAPI ");
@ -486,11 +486,22 @@ _emit_class_function(Eina_Strbuf *buf, const Eolian_Function *fid, const char *r
eina_strbuf_append_buffer(buf, params_full);
eina_strbuf_append(buf, ")\n");
eina_strbuf_append(buf, "{\n");
eina_strbuf_append_printf(buf, " %s();\n", eolian_class_c_get_function_name_get(eolian_function_class_get(fid)));
if (strcmp(rtpn, "void"))
eina_strbuf_append(buf, " return ");
eina_strbuf_append_printf(buf, " const Efl_Class *klass = %s();\n", eolian_class_c_get_function_name_get(eolian_function_class_get(fid)));
if (!!strcmp(rtpn, "void") && rtp)
{
const Eolian_Expression *default_value_expression = eolian_function_return_default_value_get(fid, ftype);
eina_strbuf_append_printf(buf, " EINA_SAFETY_ON_NULL_RETURN_VAL(klass,");
_append_defval(buf, default_value_expression, rtp, rtpn);
eina_strbuf_append_printf(buf, ");\n");
eina_strbuf_append(buf, " return ");
}
else
eina_strbuf_append(buf, " ");
{
eina_strbuf_append(buf, " EINA_SAFETY_ON_NULL_RETURN(klass);\n");
eina_strbuf_append(buf, " ");
}
eina_strbuf_append_printf(buf, "_%s", ocnamel);
eina_strbuf_append_char(buf, '_');
eina_strbuf_append(buf, eolian_function_name_get(fid));
@ -925,7 +936,7 @@ _gen_func(const Eolian_Class *cl, const Eolian_Function *fid,
eina_stringshare_del(eofn);
}
if (impl_same_class && eolian_function_is_static(fid))
_emit_class_function(buf, fid, rtpn, params_full, ocnamel, func_suffix, params, eolian_function_full_c_name_get(fid, ftype));
_emit_class_function(buf, fid, ftype, rtp, rtpn, params_full, ocnamel, func_suffix, params, eolian_function_full_c_name_get(fid, ftype));
free(cname);
free(cnamel);

View File

@ -80,7 +80,7 @@ typedef enum
*/
#define ECORE_EXE_CLASS ecore_exe_class_get()
EWAPI const Efl_Class *ecore_exe_class_get(void);
EWAPI const Efl_Class *ecore_exe_class_get(void) EINA_CONST;
/**
* @brief Controls the command that's executed. FIXME: May need a split/rename.

View File

@ -29,7 +29,7 @@ typedef struct _Ecore_Con_Reply Ecore_Con_Reply;
*/
#define ECORE_CON_EET_BASE_CLASS ecore_con_eet_base_class_get()
EWAPI const Efl_Class *ecore_con_eet_base_class_get(void);
EWAPI const Efl_Class *ecore_con_eet_base_class_get(void) EINA_CONST;
/**
* @brief The server object to which we send and receive.

View File

@ -19,6 +19,6 @@ typedef Eo Ecore_Con_Eet_Client_Obj;
*/
#define ECORE_CON_EET_CLIENT_OBJ_CLASS ecore_con_eet_client_obj_class_get()
EWAPI const Efl_Class *ecore_con_eet_client_obj_class_get(void);
EWAPI const Efl_Class *ecore_con_eet_client_obj_class_get(void) EINA_CONST;
#endif

View File

@ -19,6 +19,6 @@ typedef Eo Ecore_Con_Eet_Server_Obj;
*/
#define ECORE_CON_EET_SERVER_OBJ_CLASS ecore_con_eet_server_obj_class_get()
EWAPI const Efl_Class *ecore_con_eet_server_obj_class_get(void);
EWAPI const Efl_Class *ecore_con_eet_server_obj_class_get(void) EINA_CONST;
#endif

View File

@ -23,6 +23,6 @@ typedef Eo Edje_Edit;
*/
#define EDJE_EDIT_CLASS edje_edit_class_get()
EWAPI const Efl_Class *edje_edit_class_get(void);
EWAPI const Efl_Class *edje_edit_class_get(void) EINA_CONST;
#endif

View File

@ -26,7 +26,7 @@ typedef Eo Efl_Ui_Bg_Legacy;
*/
#define EFL_UI_BG_LEGACY_CLASS efl_ui_bg_legacy_class_get()
EWAPI const Efl_Class *efl_ui_bg_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_bg_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -24,7 +24,7 @@ typedef Eo Efl_Ui_Button_Legacy;
*/
#define EFL_UI_BUTTON_LEGACY_CLASS efl_ui_button_legacy_class_get()
EWAPI const Efl_Class *efl_ui_button_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_button_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -26,7 +26,7 @@ typedef Eo Efl_Ui_Check_Legacy;
*/
#define EFL_UI_CHECK_LEGACY_CLASS efl_ui_check_legacy_class_get()
EWAPI const Efl_Class *efl_ui_check_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_check_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Flip_Legacy;
*/
#define EFL_UI_FLIP_LEGACY_CLASS efl_ui_flip_legacy_class_get()
EWAPI const Efl_Class *efl_ui_flip_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_flip_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Focus_Parent_Provider_Gen;
*/
#define EFL_UI_FOCUS_PARENT_PROVIDER_GEN_CLASS efl_ui_focus_parent_provider_gen_class_get()
EWAPI const Efl_Class *efl_ui_focus_parent_provider_gen_class_get(void);
EWAPI const Efl_Class *efl_ui_focus_parent_provider_gen_class_get(void) EINA_CONST;
/**
* @brief Content item map property

View File

@ -25,7 +25,7 @@ typedef Eo Efl_Ui_Frame_Legacy;
*/
#define EFL_UI_FRAME_LEGACY_CLASS efl_ui_frame_legacy_class_get()
EWAPI const Efl_Class *efl_ui_frame_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_frame_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Image_Legacy;
*/
#define EFL_UI_IMAGE_LEGACY_CLASS efl_ui_image_legacy_class_get()
EWAPI const Efl_Class *efl_ui_image_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_image_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Image_Zoomable_Legacy;
*/
#define EFL_UI_IMAGE_ZOOMABLE_LEGACY_CLASS efl_ui_image_zoomable_legacy_class_get()
EWAPI const Efl_Class *efl_ui_image_zoomable_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_image_zoomable_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -21,8 +21,8 @@ typedef Eo Efl_Ui_Layout_Legacy;
#define EFL_UI_LAYOUT_LEGACY_CLASS efl_ui_layout_legacy_class_get()
#define ELM_LAYOUT_MIXIN elm_layout_mixin_get()
EWAPI const Efl_Class *efl_ui_layout_legacy_class_get(void);
EWAPI const Efl_Class *elm_layout_mixin_get(void);
EWAPI const Efl_Class *efl_ui_layout_legacy_class_get(void) EINA_CONST;
EWAPI const Efl_Class *elm_layout_mixin_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Panes_Legacy;
*/
#define EFL_UI_PANES_LEGACY_CLASS efl_ui_panes_legacy_class_get()
EWAPI const Efl_Class *efl_ui_panes_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_panes_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Progressbar_Legacy;
*/
#define EFL_UI_PROGRESSBAR_LEGACY_CLASS efl_ui_progressbar_legacy_class_get()
EWAPI const Efl_Class *efl_ui_progressbar_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_progressbar_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Radio_Legacy;
*/
#define EFL_UI_RADIO_LEGACY_CLASS efl_ui_radio_legacy_class_get()
EWAPI const Efl_Class *efl_ui_radio_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_radio_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Textpath_Legacy;
*/
#define EFL_UI_TEXTPATH_LEGACY_CLASS efl_ui_textpath_legacy_class_get()
EWAPI const Efl_Class *efl_ui_textpath_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_textpath_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -521,7 +521,7 @@ EAPI int elm_animation_view_max_frame_get(const Elm_Animation_View *obj);
*/
#define EFL_UI_VG_ANIMATION_LEGACY_CLASS efl_ui_vg_animation_legacy_class_get()
EWAPI const Efl_Class *efl_ui_vg_animation_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_vg_animation_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Video_Legacy;
*/
#define EFL_UI_VIDEO_LEGACY_CLASS efl_ui_video_legacy_class_get()
EWAPI const Efl_Class *efl_ui_video_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_video_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Win_Inlined_Legacy;
*/
#define EFL_UI_WIN_INLINED_LEGACY_CLASS efl_ui_win_inlined_legacy_class_get()
EWAPI const Efl_Class *efl_ui_win_inlined_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_win_inlined_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Win_Legacy;
*/
#define EFL_UI_WIN_LEGACY_CLASS efl_ui_win_legacy_class_get()
EWAPI const Efl_Class *efl_ui_win_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_win_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -20,7 +20,7 @@ typedef Eo Efl_Ui_Win_Socket_Legacy;
*/
#define EFL_UI_WIN_SOCKET_LEGACY_CLASS efl_ui_win_socket_legacy_class_get()
EWAPI const Efl_Class *efl_ui_win_socket_legacy_class_get(void);
EWAPI const Efl_Class *efl_ui_win_socket_legacy_class_get(void) EINA_CONST;
#endif /* EFL_BETA_API_SUPPORT */
#endif

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Access;
*/
#define ELM_ACCESS_CLASS elm_access_class_get()
EWAPI const Efl_Class *elm_access_class_get(void);
EWAPI const Efl_Class *elm_access_class_get(void) EINA_CONST;
#endif

View File

@ -38,7 +38,7 @@ typedef enum
*/
#define ELM_ACTIONSLIDER_CLASS elm_actionslider_class_get()
EWAPI const Efl_Class *elm_actionslider_class_get(void);
EWAPI const Efl_Class *elm_actionslider_class_get(void) EINA_CONST;
/**
* @brief Actionslider position indicator

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Atspi_App_Object;
*/
#define ELM_ATSPI_APP_OBJECT_CLASS elm_atspi_app_object_class_get()
EWAPI const Efl_Class *elm_atspi_app_object_class_get(void);
EWAPI const Efl_Class *elm_atspi_app_object_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Atspi_Bridge;
*/
#define ELM_ATSPI_BRIDGE_CLASS elm_atspi_bridge_class_get()
EWAPI const Efl_Class *elm_atspi_bridge_class_get(void);
EWAPI const Efl_Class *elm_atspi_bridge_class_get(void) EINA_CONST;
/**
* @brief Indicate if connection with AT-SPI2 bus has been established.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Box;
*/
#define ELM_BOX_CLASS elm_box_class_get()
EWAPI const Efl_Class *elm_box_class_get(void);
EWAPI const Efl_Class *elm_box_class_get(void) EINA_CONST;
/**
* @brief Set the box to arrange its children homogeneously

View File

@ -40,7 +40,7 @@ typedef enum
*/
#define ELM_BUBBLE_CLASS elm_bubble_class_get()
EWAPI const Efl_Class *elm_bubble_class_get(void);
EWAPI const Efl_Class *elm_bubble_class_get(void) EINA_CONST;
/**
* @brief The corner of the bubble

View File

@ -128,7 +128,7 @@ typedef struct _Elm_Calendar_Mark Elm_Calendar_Mark;
*/
#define ELM_CALENDAR_CLASS elm_calendar_class_get()
EWAPI const Efl_Class *elm_calendar_class_get(void);
EWAPI const Efl_Class *elm_calendar_class_get(void) EINA_CONST;
/**
* @brief The first day of week to use on calendar widgets'.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Calendar_Item;
*/
#define ELM_CALENDAR_ITEM_CLASS elm_calendar_item_class_get()
EWAPI const Efl_Class *elm_calendar_item_class_get(void);
EWAPI const Efl_Class *elm_calendar_item_class_get(void) EINA_CONST;
/**
* @brief Day number property

View File

@ -56,7 +56,7 @@ typedef enum
*/
#define ELM_CLOCK_CLASS elm_clock_class_get()
EWAPI const Efl_Class *elm_clock_class_get(void);
EWAPI const Efl_Class *elm_clock_class_get(void) EINA_CONST;
/**
* @brief If the given clock widget must show hours in military or am/pm mode

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Code_Widget_Legacy;
*/
#define ELM_CODE_WIDGET_LEGACY_CLASS elm_code_widget_legacy_class_get()
EWAPI const Efl_Class *elm_code_widget_legacy_class_get(void);
EWAPI const Efl_Class *elm_code_widget_legacy_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Color_Item;
*/
#define ELM_COLOR_ITEM_CLASS elm_color_item_class_get()
EWAPI const Efl_Class *elm_color_item_class_get(void);
EWAPI const Efl_Class *elm_color_item_class_get(void) EINA_CONST;
/**
* @brief Set Palette item's color.

View File

@ -37,7 +37,7 @@ typedef enum
*/
#define ELM_COLORSELECTOR_CLASS elm_colorselector_class_get()
EWAPI const Efl_Class *elm_colorselector_class_get(void);
EWAPI const Efl_Class *elm_colorselector_class_get(void) EINA_CONST;
/**
* @brief Set color to colorselector.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Conformant;
*/
#define ELM_CONFORMANT_CLASS elm_conformant_class_get()
EWAPI const Efl_Class *elm_conformant_class_get(void);
EWAPI const Efl_Class *elm_conformant_class_get(void) EINA_CONST;
EWAPI extern const Efl_Event_Description _ELM_CONFORMANT_EVENT_VIRTUALKEYPAD_STATE_ON;

View File

@ -37,7 +37,7 @@ typedef enum
*/
#define ELM_CTXPOPUP_CLASS elm_ctxpopup_class_get()
EWAPI const Efl_Class *elm_ctxpopup_class_get(void);
EWAPI const Efl_Class *elm_ctxpopup_class_get(void) EINA_CONST;
/**
* @brief Get the selected item in the widget.

View File

@ -27,7 +27,7 @@ typedef Eo Elm_Ctxpopup_Item;
*/
#define ELM_CTXPOPUP_ITEM_CLASS elm_ctxpopup_item_class_get()
EWAPI const Efl_Class *elm_ctxpopup_item_class_get(void);
EWAPI const Efl_Class *elm_ctxpopup_item_class_get(void) EINA_CONST;
/**
* @brief Get the item before this one in the widget's list of items.

View File

@ -41,7 +41,7 @@ typedef enum
*/
#define ELM_DAYSELECTOR_CLASS elm_dayselector_class_get()
EWAPI const Efl_Class *elm_dayselector_class_get(void);
EWAPI const Efl_Class *elm_dayselector_class_get(void) EINA_CONST;
/**
* @brief Set the starting day of Dayselector.

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Dayselector_Item;
*/
#define ELM_DAYSELECTOR_ITEM_CLASS elm_dayselector_item_class_get()
EWAPI const Efl_Class *elm_dayselector_item_class_get(void);
EWAPI const Efl_Class *elm_dayselector_item_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Diskselector;
*/
#define ELM_DISKSELECTOR_CLASS elm_diskselector_class_get()
EWAPI const Efl_Class *elm_diskselector_class_get(void);
EWAPI const Efl_Class *elm_diskselector_class_get(void) EINA_CONST;
/**
* @brief Set the side labels max length.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Diskselector_Item;
*/
#define ELM_DISKSELECTOR_ITEM_CLASS elm_diskselector_item_class_get()
EWAPI const Efl_Class *elm_diskselector_item_class_get(void);
EWAPI const Efl_Class *elm_diskselector_item_class_get(void) EINA_CONST;
/**
* @brief Get the item before @c item in diskselector.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Entry;
*/
#define ELM_ENTRY_CLASS elm_entry_class_get()
EWAPI const Efl_Class *elm_entry_class_get(void);
EWAPI const Efl_Class *elm_entry_class_get(void) EINA_CONST;
/**
* @brief Enable or disable scrolling in entry

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Fileselector_Button;
*/
#define ELM_FILESELECTOR_BUTTON_CLASS elm_fileselector_button_class_get()
EWAPI const Efl_Class *elm_fileselector_button_class_get(void);
EWAPI const Efl_Class *elm_fileselector_button_class_get(void) EINA_CONST;
EWAPI extern const Efl_Event_Description _ELM_FILESELECTOR_BUTTON_EVENT_FILE_CHOSEN;

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Fileselector_Entry;
*/
#define ELM_FILESELECTOR_ENTRY_CLASS elm_fileselector_entry_class_get()
EWAPI const Efl_Class *elm_fileselector_entry_class_get(void);
EWAPI const Efl_Class *elm_fileselector_entry_class_get(void) EINA_CONST;
EWAPI extern const Efl_Event_Description _ELM_FILESELECTOR_ENTRY_EVENT_CHANGED;

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Fileselector;
*/
#define ELM_FILESELECTOR_CLASS elm_fileselector_class_get()
EWAPI const Efl_Class *elm_fileselector_class_get(void);
EWAPI const Efl_Class *elm_fileselector_class_get(void) EINA_CONST;
/**
* @brief Enable/disable the "ok" and "cancel" buttons on a given file selector

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Flipselector;
*/
#define ELM_FLIPSELECTOR_CLASS elm_flipselector_class_get()
EWAPI const Efl_Class *elm_flipselector_class_get(void);
EWAPI const Efl_Class *elm_flipselector_class_get(void) EINA_CONST;
/**
* @brief Get the internal list of items in a given flip selector widget.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Flipselector_Item;
*/
#define ELM_FLIPSELECTOR_ITEM_CLASS elm_flipselector_item_class_get()
EWAPI const Efl_Class *elm_flipselector_item_class_get(void);
EWAPI const Efl_Class *elm_flipselector_item_class_get(void) EINA_CONST;
/**
* @brief Set whether a given flip selector widget's item should be the

View File

@ -29,7 +29,7 @@ typedef enum
*/
#define ELM_GENGRID_CLASS elm_gengrid_class_get()
EWAPI const Efl_Class *elm_gengrid_class_get(void);
EWAPI const Efl_Class *elm_gengrid_class_get(void) EINA_CONST;
/**
* @brief Set the items grid's alignment within a given gengrid widget.

View File

@ -27,7 +27,7 @@ typedef Eo Elm_Gengrid_Item;
*/
#define ELM_GENGRID_ITEM_CLASS elm_gengrid_item_class_get()
EWAPI const Efl_Class *elm_gengrid_item_class_get(void);
EWAPI const Efl_Class *elm_gengrid_item_class_get(void) EINA_CONST;
/**
* @brief Get the previous item in a gengrid widget's internal list of items,

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Gengrid_Pan;
*/
#define ELM_GENGRID_PAN_CLASS elm_gengrid_pan_class_get()
EWAPI const Efl_Class *elm_gengrid_pan_class_get(void);
EWAPI const Efl_Class *elm_gengrid_pan_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Genlist;
*/
#define ELM_GENLIST_CLASS elm_genlist_class_get()
EWAPI const Efl_Class *elm_genlist_class_get(void);
EWAPI const Efl_Class *elm_genlist_class_get(void) EINA_CONST;
/**
* @brief Enable/disable homogeneous mode.

View File

@ -27,7 +27,7 @@ typedef Eo Elm_Genlist_Item;
*/
#define ELM_GENLIST_ITEM_CLASS elm_genlist_item_class_get()
EWAPI const Efl_Class *elm_genlist_item_class_get(void);
EWAPI const Efl_Class *elm_genlist_item_class_get(void) EINA_CONST;
/**
* @brief Get the previous item in a genlist widget's internal list of items,

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Genlist_Pan;
*/
#define ELM_GENLIST_PAN_CLASS elm_genlist_pan_class_get()
EWAPI const Efl_Class *elm_genlist_pan_class_get(void);
EWAPI const Efl_Class *elm_genlist_pan_class_get(void) EINA_CONST;
#endif

View File

@ -52,7 +52,7 @@ typedef enum
*/
#define ELM_GESTURE_LAYER_CLASS elm_gesture_layer_class_get()
EWAPI const Efl_Class *elm_gesture_layer_class_get(void);
EWAPI const Efl_Class *elm_gesture_layer_class_get(void) EINA_CONST;
/**
* @brief Control step value for zoom action.

View File

@ -118,7 +118,7 @@ typedef enum
*/
#define ELM_GLVIEW_CLASS elm_glview_class_get()
EWAPI const Efl_Class *elm_glview_class_get(void);
EWAPI const Efl_Class *elm_glview_class_get(void) EINA_CONST;
/**
* @brief Constructor with context version number.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Grid;
*/
#define ELM_GRID_CLASS elm_grid_class_get()
EWAPI const Efl_Class *elm_grid_class_get(void);
EWAPI const Efl_Class *elm_grid_class_get(void) EINA_CONST;
/**
* @brief Set the virtual size of the grid

View File

@ -32,7 +32,7 @@ typedef enum
*/
#define ELM_HOVER_CLASS elm_hover_class_get()
EWAPI const Efl_Class *elm_hover_class_get(void);
EWAPI const Efl_Class *elm_hover_class_get(void) EINA_CONST;
/**
* @brief Sets the target object for the hover.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Hoversel;
*/
#define ELM_HOVERSEL_CLASS elm_hoversel_class_get()
EWAPI const Efl_Class *elm_hoversel_class_get(void);
EWAPI const Efl_Class *elm_hoversel_class_get(void) EINA_CONST;
/**
* @brief Control if the hoversel should expand horizontally.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Hoversel_Item;
*/
#define ELM_HOVERSEL_ITEM_CLASS elm_hoversel_item_class_get()
EWAPI const Efl_Class *elm_hoversel_item_class_get(void);
EWAPI const Efl_Class *elm_hoversel_item_class_get(void) EINA_CONST;
/**
* @brief This controls the icon for the given hoversel item.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Icon;
*/
#define ELM_ICON_CLASS elm_icon_class_get()
EWAPI const Efl_Class *elm_icon_class_get(void);
EWAPI const Efl_Class *elm_icon_class_get(void) EINA_CONST;
EWAPI extern const Efl_Event_Description _ELM_ICON_EVENT_THUMB_DONE;

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Index;
*/
#define ELM_INDEX_CLASS elm_index_class_get()
EWAPI const Efl_Class *elm_index_class_get(void);
EWAPI const Efl_Class *elm_index_class_get(void) EINA_CONST;
/**
* @brief Enable or disable auto hiding feature for a given index widget.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Index_Item;
*/
#define ELM_INDEX_ITEM_CLASS elm_index_item_class_get()
EWAPI const Efl_Class *elm_index_item_class_get(void);
EWAPI const Efl_Class *elm_index_item_class_get(void) EINA_CONST;
/**
* @brief Set the selected state of an item.

View File

@ -53,7 +53,7 @@ typedef enum
*/
#define ELM_INTERFACE_FILESELECTOR_INTERFACE elm_interface_fileselector_interface_get()
EWAPI const Efl_Class *elm_interface_fileselector_interface_get(void);
EWAPI const Efl_Class *elm_interface_fileselector_interface_get(void) EINA_CONST;
/**
* @brief Enable/disable folder-only view for a given file selector widget

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Inwin;
*/
#define ELM_INWIN_CLASS elm_inwin_class_get()
EWAPI const Efl_Class *elm_inwin_class_get(void);
EWAPI const Efl_Class *elm_inwin_class_get(void) EINA_CONST;
/**
* @brief Activates an inwin object, ensuring its visibility

View File

@ -31,7 +31,7 @@ typedef enum
*/
#define ELM_LABEL_CLASS elm_label_class_get()
EWAPI const Efl_Class *elm_label_class_get(void);
EWAPI const Efl_Class *elm_label_class_get(void) EINA_CONST;
/**
* @brief Control wrap width of the label

View File

@ -19,7 +19,7 @@ typedef Eo Elm_List;
*/
#define ELM_LIST_CLASS elm_list_class_get()
EWAPI const Efl_Class *elm_list_class_get(void);
EWAPI const Efl_Class *elm_list_class_get(void) EINA_CONST;
/**
* @brief Control horizontal mode on the list object.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_List_Item;
*/
#define ELM_LIST_ITEM_CLASS elm_list_item_class_get()
EWAPI const Efl_Class *elm_list_item_class_get(void);
EWAPI const Efl_Class *elm_list_item_class_get(void) EINA_CONST;
/**
* @brief Set or unset item as a separator.

View File

@ -69,7 +69,7 @@ typedef enum
*/
#define ELM_MAP_CLASS elm_map_class_get()
EWAPI const Efl_Class *elm_map_class_get(void);
EWAPI const Efl_Class *elm_map_class_get(void) EINA_CONST;
/**
* @brief Set the minimum zoom of the source.

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Map_Pan;
*/
#define ELM_MAP_PAN_CLASS elm_map_pan_class_get()
EWAPI const Efl_Class *elm_map_pan_class_get(void);
EWAPI const Efl_Class *elm_map_pan_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Mapbuf;
*/
#define ELM_MAPBUF_CLASS elm_mapbuf_class_get()
EWAPI const Efl_Class *elm_mapbuf_class_get(void);
EWAPI const Efl_Class *elm_mapbuf_class_get(void) EINA_CONST;
/**
* @brief Set or unset auto flag for map rendering.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Menu;
*/
#define ELM_MENU_CLASS elm_menu_class_get()
EWAPI const Efl_Class *elm_menu_class_get(void);
EWAPI const Efl_Class *elm_menu_class_get(void) EINA_CONST;
/**
* @brief Get the selected item in the widget.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Menu_Item;
*/
#define ELM_MENU_ITEM_CLASS elm_menu_item_class_get()
EWAPI const Efl_Class *elm_menu_item_class_get(void);
EWAPI const Efl_Class *elm_menu_item_class_get(void) EINA_CONST;
/**
* @brief Set the icon of a menu item to the standard icon with the given name.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Multibuttonentry;
*/
#define ELM_MULTIBUTTONENTRY_CLASS elm_multibuttonentry_class_get()
EWAPI const Efl_Class *elm_multibuttonentry_class_get(void);
EWAPI const Efl_Class *elm_multibuttonentry_class_get(void) EINA_CONST;
/**
* @brief Control if the multibuttonentry is to be editable or not.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Multibuttonentry_Item;
*/
#define ELM_MULTIBUTTONENTRY_ITEM_CLASS elm_multibuttonentry_item_class_get()
EWAPI const Efl_Class *elm_multibuttonentry_item_class_get(void);
EWAPI const Efl_Class *elm_multibuttonentry_item_class_get(void) EINA_CONST;
/**
* @brief Control the selected state of an item

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Naviframe;
*/
#define ELM_NAVIFRAME_CLASS elm_naviframe_class_get()
EWAPI const Efl_Class *elm_naviframe_class_get(void);
EWAPI const Efl_Class *elm_naviframe_class_get(void) EINA_CONST;
/**
* @brief Control the event enabled when pushing/popping items

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Naviframe_Item;
*/
#define ELM_NAVIFRAME_ITEM_CLASS elm_naviframe_item_class_get()
EWAPI const Efl_Class *elm_naviframe_item_class_get(void);
EWAPI const Efl_Class *elm_naviframe_item_class_get(void) EINA_CONST;
/**
* @brief Pop the top item and delete the items between the top and the above

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Notify;
*/
#define ELM_NOTIFY_CLASS elm_notify_class_get()
EWAPI const Efl_Class *elm_notify_class_get(void);
EWAPI const Efl_Class *elm_notify_class_get(void) EINA_CONST;
/**
* @brief Set the alignment of the notify object

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Pan;
*/
#define ELM_PAN_CLASS elm_pan_class_get()
EWAPI const Efl_Class *elm_pan_class_get(void);
EWAPI const Efl_Class *elm_pan_class_get(void) EINA_CONST;
/**
* @brief Position

View File

@ -31,7 +31,7 @@ typedef enum
*/
#define ELM_PANEL_CLASS elm_panel_class_get()
EWAPI const Efl_Class *elm_panel_class_get(void);
EWAPI const Efl_Class *elm_panel_class_get(void) EINA_CONST;
/**
* @brief Set the orientation of the panel

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Photo;
*/
#define ELM_PHOTO_CLASS elm_photo_class_get()
EWAPI const Efl_Class *elm_photo_class_get(void);
EWAPI const Efl_Class *elm_photo_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Player;
*/
#define ELM_PLAYER_CLASS elm_player_class_get()
EWAPI const Efl_Class *elm_player_class_get(void);
EWAPI const Efl_Class *elm_player_class_get(void) EINA_CONST;
EWAPI extern const Efl_Event_Description _ELM_PLAYER_EVENT_FORWARD_CLICKED;

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Plug;
*/
#define ELM_PLUG_CLASS elm_plug_class_get()
EWAPI const Efl_Class *elm_plug_class_get(void);
EWAPI const Efl_Class *elm_plug_class_get(void) EINA_CONST;
/**
* @brief Get the basic Evas_Image object from this object (widget).

View File

@ -49,7 +49,7 @@ typedef enum
*/
#define ELM_POPUP_CLASS elm_popup_class_get()
EWAPI const Efl_Class *elm_popup_class_get(void);
EWAPI const Efl_Class *elm_popup_class_get(void) EINA_CONST;
/**
* @brief Set the alignment of the popup object.

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Popup_Item;
*/
#define ELM_POPUP_ITEM_CLASS elm_popup_item_class_get()
EWAPI const Efl_Class *elm_popup_item_class_get(void);
EWAPI const Efl_Class *elm_popup_item_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Prefs;
*/
#define ELM_PREFS_CLASS elm_prefs_class_get()
EWAPI const Efl_Class *elm_prefs_class_get(void);
EWAPI const Efl_Class *elm_prefs_class_get(void) EINA_CONST;
/**
* @brief Set user data for a given prefs widget

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Route;
*/
#define ELM_ROUTE_CLASS elm_route_class_get()
EWAPI const Efl_Class *elm_route_class_get(void);
EWAPI const Efl_Class *elm_route_class_get(void) EINA_CONST;
/**
* @brief Set map widget for this route

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Scroller;
*/
#define ELM_SCROLLER_CLASS elm_scroller_class_get()
EWAPI const Efl_Class *elm_scroller_class_get(void);
EWAPI const Efl_Class *elm_scroller_class_get(void) EINA_CONST;
/**
* @brief Set custom theme elements for the scroller

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Segment_Control;
*/
#define ELM_SEGMENT_CONTROL_CLASS elm_segment_control_class_get()
EWAPI const Efl_Class *elm_segment_control_class_get(void);
EWAPI const Efl_Class *elm_segment_control_class_get(void) EINA_CONST;
/**
* @brief Get the Segment items count from segment control.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Segment_Control_Item;
*/
#define ELM_SEGMENT_CONTROL_ITEM_CLASS elm_segment_control_item_class_get()
EWAPI const Efl_Class *elm_segment_control_item_class_get(void);
EWAPI const Efl_Class *elm_segment_control_item_class_get(void) EINA_CONST;
/**
* @brief Get the index of an item.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Separator;
*/
#define ELM_SEPARATOR_CLASS elm_separator_class_get()
EWAPI const Efl_Class *elm_separator_class_get(void);
EWAPI const Efl_Class *elm_separator_class_get(void) EINA_CONST;
/**
* @brief Set the horizontal mode of a separator object

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Slider;
*/
#define ELM_SLIDER_CLASS elm_slider_class_get()
EWAPI const Efl_Class *elm_slider_class_get(void);
EWAPI const Efl_Class *elm_slider_class_get(void) EINA_CONST;
#endif

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Slider_Part_Indicator;
*/
#define ELM_SLIDER_PART_INDICATOR_CLASS elm_slider_part_indicator_class_get()
EWAPI const Efl_Class *elm_slider_part_indicator_class_get(void);
EWAPI const Efl_Class *elm_slider_part_indicator_class_get(void) EINA_CONST;
/**
* @brief Set/Get the visible mode of indicator.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Slideshow;
*/
#define ELM_SLIDESHOW_CLASS elm_slideshow_class_get()
EWAPI const Efl_Class *elm_slideshow_class_get(void);
EWAPI const Efl_Class *elm_slideshow_class_get(void) EINA_CONST;
/**
* @brief Set the number of items to cache, on a given slideshow widget, after

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Slideshow_Item;
*/
#define ELM_SLIDESHOW_ITEM_CLASS elm_slideshow_item_class_get()
EWAPI const Efl_Class *elm_slideshow_item_class_get(void);
EWAPI const Efl_Class *elm_slideshow_item_class_get(void) EINA_CONST;
/**
* @brief Display a given slideshow widget's item, programmatically.

View File

@ -19,7 +19,7 @@ typedef Eo Elm_Spinner;
*/
#define ELM_SPINNER_CLASS elm_spinner_class_get()
EWAPI const Efl_Class *elm_spinner_class_get(void);
EWAPI const Efl_Class *elm_spinner_class_get(void) EINA_CONST;
/**
* @brief Control whether the spinner should wrap when it reaches its minimum

View File

@ -19,6 +19,6 @@ typedef Eo Elm_Sys_Notify_Dbus;
*/
#define ELM_SYS_NOTIFY_DBUS_CLASS elm_sys_notify_dbus_class_get()
EWAPI const Efl_Class *elm_sys_notify_dbus_class_get(void);
EWAPI const Efl_Class *elm_sys_notify_dbus_class_get(void) EINA_CONST;
#endif

View File

@ -11,12 +11,14 @@ Elm_Sys_Notify *_elm_sys_notify_singleton_get(void);
EOAPI Elm_Sys_Notify * elm_obj_sys_notify_singleton_get(void)
{
elm_sys_notify_class_get();
const Efl_Class *klass = elm_sys_notify_class_get();
EINA_SAFETY_ON_NULL_RETURN_VAL(klass, NULL);
return _elm_sys_notify_singleton_get();
}
EOAPI Elm_Sys_Notify * elm_sys_notify_singleton_get(void)
{
elm_sys_notify_class_get();
const Efl_Class *klass = elm_sys_notify_class_get();
EINA_SAFETY_ON_NULL_RETURN_VAL(klass, NULL);
return _elm_sys_notify_singleton_get();
}

Some files were not shown because too many files have changed in this diff Show More