forked from enlightenment/edi
Fix the types of Eo Events - addresses lots of compiler warnings
This commit is contained in:
parent
e3fd501e9b
commit
131a686c78
|
@ -7,6 +7,7 @@ AM_CPPFLAGS = -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \
|
|||
-I$(top_srcdir)/elm_code/bin/ \
|
||||
-I$(top_builddir)/elm_code/lib/ \
|
||||
-I$(top_srcdir)/elm_code/lib/ \
|
||||
-DEFL_BETA_API_SUPPORT \
|
||||
@EFL_CFLAGS@
|
||||
|
||||
elm_code_test_SOURCES = elm_code_test_main.c
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# define ELM_CODE_H_
|
||||
|
||||
#include <Elementary.h>
|
||||
|
||||
#include <Eo.h>
|
||||
#include <Eina.h>
|
||||
|
||||
#include <elm_code_common.h>
|
||||
|
@ -119,7 +119,7 @@ EAPI void elm_code_free(Elm_Code *code);
|
|||
*/
|
||||
|
||||
|
||||
EAPI void elm_code_callback_fire(Elm_Code *code, const char *signal, void *data);
|
||||
EAPI void elm_code_callback_fire(Elm_Code *code, const Eo_Event_Description *signal, void *data);
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -5,6 +5,7 @@ AM_CPPFLAGS = \
|
|||
-I$(top_builddir)/elm_code/lib \
|
||||
-DPACKAGE_LIB_DIR=\"$(libdir)\" \
|
||||
-DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \
|
||||
-DEFL_BETA_API_SUPPORT \
|
||||
@EFL_CFLAGS@ \
|
||||
-DEFL_EFL_BUILD
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
# include "config.h"
|
||||
#endif
|
||||
|
||||
#define EFL_BETA_API_SUPPORT
|
||||
#include <Eo.h>
|
||||
|
||||
#include "Elm_Code.h"
|
||||
|
@ -12,6 +11,9 @@
|
|||
static int _elm_code_init = 0;
|
||||
int _elm_code_lib_log_dom = -1;
|
||||
|
||||
const Eo_Event_Description ELM_CODE_EVENT_LINE_SET_DONE =
|
||||
EO_EVENT_DESCRIPTION("line,set,done", "");
|
||||
|
||||
EAPI int
|
||||
elm_code_init(void)
|
||||
{
|
||||
|
@ -91,14 +93,14 @@ elm_code_free(Elm_Code *code)
|
|||
}
|
||||
|
||||
EAPI void
|
||||
elm_code_callback_fire(Elm_Code *code, const char *signal, void *data)
|
||||
elm_code_callback_fire(Elm_Code *code, const Eo_Event_Description *signal, void *data)
|
||||
{
|
||||
Eina_List *item;
|
||||
Evas_Object *widget;
|
||||
|
||||
EINA_LIST_FOREACH(code->widgets, item, widget)
|
||||
{
|
||||
eo_do(widget, eo_event_callback_call((Eo_Event_Description *)signal, data));
|
||||
eo_do(widget, eo_event_callback_call(signal, data));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,12 +1,10 @@
|
|||
#ifndef ELM_CODE_COMMON_H_
|
||||
# define ELM_CODE_COMMON_H_
|
||||
|
||||
#include <Eo.h>
|
||||
#include <Eina.h>
|
||||
|
||||
// TODO figure out how this can be fixed
|
||||
#define ELM_CODE_EVENT_LINE_SET_DONE "line,set,done"
|
||||
//EAPI const Eo_Event_Description ELM_CODE_EVENT_LINE_SET_DONE =
|
||||
// EO_EVENT_DESCRIPTION("line,set,done", "");
|
||||
EAPI extern const Eo_Event_Description ELM_CODE_EVENT_LINE_SET_DONE;
|
||||
|
||||
typedef enum {
|
||||
ELM_CODE_STATUS_TYPE_DEFAULT = 0,
|
||||
|
|
|
@ -33,7 +33,7 @@ static void _elm_code_file_line_append_data(Elm_Code_File *file, const char *con
|
|||
file->lines = eina_list_append(file->lines, line);
|
||||
|
||||
if (file->parent)
|
||||
elm_code_callback_fire(file->parent, ELM_CODE_EVENT_LINE_SET_DONE, line);
|
||||
elm_code_callback_fire(file->parent, &ELM_CODE_EVENT_LINE_SET_DONE, line);
|
||||
}
|
||||
|
||||
EAPI Elm_Code_File *elm_code_file_new()
|
||||
|
@ -152,5 +152,5 @@ EAPI void elm_code_file_line_status_set(Elm_Code_File *file, unsigned int number
|
|||
line->status = status;
|
||||
|
||||
if (file->parent)
|
||||
elm_code_callback_fire(file->parent, ELM_CODE_EVENT_LINE_SET_DONE, line);
|
||||
elm_code_callback_fire(file->parent, &ELM_CODE_EVENT_LINE_SET_DONE, line);
|
||||
}
|
||||
|
|
|
@ -2,9 +2,7 @@
|
|||
# include "config.h"
|
||||
#endif
|
||||
|
||||
#define EFL_BETA_API_SUPPORT
|
||||
#include <Eo.h>
|
||||
|
||||
#include <Elementary.h>
|
||||
|
||||
#include "elm_code_widget.h"
|
||||
|
@ -131,7 +129,7 @@ EAPI Evas_Object *elm_code_widget_add(Evas_Object *parent, Elm_Code *code)
|
|||
|
||||
evas_object_event_callback_add(o, EVAS_CALLBACK_RESIZE, _elm_code_widget_resize_cb, code);
|
||||
|
||||
eo_do(o,eo_event_callback_add((Eo_Event_Description *)ELM_CODE_EVENT_LINE_SET_DONE, _elm_code_widget_line_cb, code));
|
||||
eo_do(o,eo_event_callback_add(&ELM_CODE_EVENT_LINE_SET_DONE, _elm_code_widget_line_cb, code));
|
||||
|
||||
code->widgets = eina_list_append(code->widgets, o);
|
||||
return o;
|
||||
|
|
|
@ -8,7 +8,7 @@ AM_CPPFLAGS = -DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \
|
|||
-I$(top_srcdir)/src/bin/ \
|
||||
-I$(top_srcdir)/elm_code/lib \
|
||||
-I$(top_builddir)/src/lib/ \
|
||||
-I$(top_srcdir)/src/lib/ \
|
||||
-DEFL_BETA_API_SUPPORT \
|
||||
@EFL_CFLAGS@
|
||||
|
||||
edi_SOURCES = \
|
||||
|
|
Loading…
Reference in New Issue