\hypertarget{group__Ecore__Event__Group}{}\doxysection{Ecore Event functions}
\label{group__Ecore__Event__Group}\index{Ecore Event functions@{Ecore Event functions}}


Ecore events provide two main features that are of use to those using ecore\+: creating events and being notified of events.  


\doxysubsection*{Modules}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{group__Ecore__System__Events}{System Events}}
\begin{DoxyCompactList}\small\item\em Ecore is aware of some system events that one may be interested, they are described below\+: \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct \mbox{\hyperlink{struct__Ecore__Event__Signal__User}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+User}}
\begin{DoxyCompactList}\small\item\em A structure that stores information of a User signal event. \end{DoxyCompactList}\item 
struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Hup}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Hup}}
\begin{DoxyCompactList}\small\item\em A structure that stores information of a Hup signal event. \end{DoxyCompactList}\item 
struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Exit}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Exit}}
\begin{DoxyCompactList}\small\item\em A structure that stores information of an Exit request event. \end{DoxyCompactList}\item 
struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Power}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Power}}
\begin{DoxyCompactList}\small\item\em A structure that stores information of a Power event. \end{DoxyCompactList}\item 
struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Realtime}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Realtime}}
\begin{DoxyCompactList}\small\item\em A structure that stores information of a Realtime event. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}\label{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+NONE}~0
\begin{DoxyCompactList}\small\item\em None event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gab1c2ecd8bba5f957ce06f06fc7e7743d}\label{group__Ecore__Event__Group_gab1c2ecd8bba5f957ce06f06fc7e7743d}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+USER}~1
\begin{DoxyCompactList}\small\item\em User signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga3d04f0c2c30998957d968120659dc69f}\label{group__Ecore__Event__Group_ga3d04f0c2c30998957d968120659dc69f}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+HUP}~2
\begin{DoxyCompactList}\small\item\em Hup signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga0dd1e36930ae8fa8decc97564d57f310}\label{group__Ecore__Event__Group_ga0dd1e36930ae8fa8decc97564d57f310}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+EXIT}~3
\begin{DoxyCompactList}\small\item\em Exit signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga574bf58511179b54078843611c008811}\label{group__Ecore__Event__Group_ga574bf58511179b54078843611c008811}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+POWER}~4
\begin{DoxyCompactList}\small\item\em Power signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gae4ce1d886fba149d60d3df1d8de05853}\label{group__Ecore__Event__Group_gae4ce1d886fba149d60d3df1d8de05853}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+REALTIME}~5
\begin{DoxyCompactList}\small\item\em Realtime signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga95e027b2b9f5817cfa57505cc9990f5a}\label{group__Ecore__Event__Group_ga95e027b2b9f5817cfa57505cc9990f5a}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+MEMORY\+\_\+\+STATE}~6
\begin{DoxyCompactList}\small\item\em Memory state changed, see \mbox{\hyperlink{group__Ecore__System__Events_gaedb05c29f8d7f347d734c567b8a110f6}{ecore\+\_\+memory\+\_\+state\+\_\+get()}} \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gaf3f2a9900d5e256ab709f7e17ef0e377}\label{group__Ecore__Event__Group_gaf3f2a9900d5e256ab709f7e17ef0e377}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+POWER\+\_\+\+STATE}~7
\begin{DoxyCompactList}\small\item\em Power state changed, see \mbox{\hyperlink{group__Ecore__System__Events_ga224a33889b5f3e7496faabe9df7a640e}{ecore\+\_\+power\+\_\+state\+\_\+get()}} \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gaa598cc77cba5cbed8ecc617b4b842180}\label{group__Ecore__Event__Group_gaa598cc77cba5cbed8ecc617b4b842180}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+LOCALE\+\_\+\+CHANGED}~8
\begin{DoxyCompactList}\small\item\em Locale changed. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga55026160dc580bf7f9df3584cb28a403}\label{group__Ecore__Event__Group_ga55026160dc580bf7f9df3584cb28a403}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+HOSTNAME\+\_\+\+CHANGED}~9
\begin{DoxyCompactList}\small\item\em Hostname changed. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga040ac4c1a598c01996403da7a8c6fd4b}\label{group__Ecore__Event__Group_ga040ac4c1a598c01996403da7a8c6fd4b}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+SYSTEM\+\_\+\+TIMEDATE\+\_\+\+CHANGED}~10
\begin{DoxyCompactList}\small\item\em Time or Date changed. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga01df0d55042d207be8ba61cbfe62d8f0}\label{group__Ecore__Event__Group_ga01df0d55042d207be8ba61cbfe62d8f0}} 
\#define {\bfseries ECORE\+\_\+\+EVENT\+\_\+\+COUNT}~11
\begin{DoxyCompactList}\small\item\em Number of events. \end{DoxyCompactList}\item 
\#define \mbox{\hyperlink{group__Ecore__Event__Group_gab7200780b0a2b7fca55f36a90119f0ce}{ecore\+\_\+event\+\_\+type\+\_\+flush}}(...)~  \mbox{\hyperlink{group__Ecore__Event__Group_ga02391c0cd64135b4121e96cae897969b}{ecore\+\_\+event\+\_\+type\+\_\+flush\+\_\+internal}}(\+\_\+\+\_\+\+VA\+\_\+\+ARGS\+\_\+\+\_\+, \mbox{\hyperlink{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}{ECORE\+\_\+\+EVENT\+\_\+\+NONE}});
\begin{DoxyCompactList}\small\item\em Forcefully flush all pending type without processing them. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga0b36f54d74bcfb8dc622844d959c9b64}\label{group__Ecore__Event__Group_ga0b36f54d74bcfb8dc622844d959c9b64}} 
typedef struct \+\_\+\+Ecore\+\_\+\+Win32\+\_\+\+Handler {\bfseries Ecore\+\_\+\+Win32\+\_\+\+Handler}
\begin{DoxyCompactList}\small\item\em A handle for HANDLE handlers on Windows. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}\label{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}} 
typedef struct \+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Handler {\bfseries Ecore\+\_\+\+Event\+\_\+\+Handler}
\begin{DoxyCompactList}\small\item\em A handle for an event handler. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}\label{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}} 
typedef struct \+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Filter {\bfseries Ecore\+\_\+\+Event\+\_\+\+Filter}
\begin{DoxyCompactList}\small\item\em A handle for an event filter. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}\label{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}} 
typedef struct \+\_\+\+Ecore\+\_\+\+Event {\bfseries Ecore\+\_\+\+Event}
\begin{DoxyCompactList}\small\item\em A handle for an event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga02bd65bebca736e324b11d61f4adef45}\label{group__Ecore__Event__Group_ga02bd65bebca736e324b11d61f4adef45}} 
typedef struct \mbox{\hyperlink{struct__Ecore__Event__Signal__User}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+User}} {\bfseries Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+User}
\begin{DoxyCompactList}\small\item\em User signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gaf3eaa720e4890961b2cf519ee5cd253d}\label{group__Ecore__Event__Group_gaf3eaa720e4890961b2cf519ee5cd253d}} 
typedef struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Hup}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Hup}} {\bfseries Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Hup}
\begin{DoxyCompactList}\small\item\em Hup signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga654cd9d55a25e2c858007967085cd2aa}\label{group__Ecore__Event__Group_ga654cd9d55a25e2c858007967085cd2aa}} 
typedef struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Exit}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Exit}} {\bfseries Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Exit}
\begin{DoxyCompactList}\small\item\em Exit signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga99878553b16a3f0c61eef2c4d291d7aa}\label{group__Ecore__Event__Group_ga99878553b16a3f0c61eef2c4d291d7aa}} 
typedef struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Power}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Power}} {\bfseries Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Power}
\begin{DoxyCompactList}\small\item\em Power signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_gaf4f3d2a3d3f6e525453bccf0d415c49f}\label{group__Ecore__Event__Group_gaf4f3d2a3d3f6e525453bccf0d415c49f}} 
typedef struct \mbox{\hyperlink{struct__Ecore__Event__Signal__Realtime}{\+\_\+\+Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Realtime}} {\bfseries Ecore\+\_\+\+Event\+\_\+\+Signal\+\_\+\+Realtime}
\begin{DoxyCompactList}\small\item\em Realtime signal event. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga0b7b5c494bd8f55a5068786b2caaf6c3}\label{group__Ecore__Event__Group_ga0b7b5c494bd8f55a5068786b2caaf6c3}} 
typedef \mbox{\hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool}}($\ast$ {\bfseries Ecore\+\_\+\+Filter\+\_\+\+Cb}) (void $\ast$data, void $\ast$loop\+\_\+data, int type, void $\ast$event)
\begin{DoxyCompactList}\small\item\em A callback used for filtering events from the main loop. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}\label{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}} 
typedef void($\ast$ {\bfseries Ecore\+\_\+\+End\+\_\+\+Cb}) (void $\ast$user\+\_\+data, void $\ast$func\+\_\+data)
\begin{DoxyCompactList}\small\item\em This is the callback which is called at the end of a function, usually for cleanup purposes. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}\label{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}} 
typedef \mbox{\hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool}}($\ast$ {\bfseries Ecore\+\_\+\+Event\+\_\+\+Handler\+\_\+\+Cb}) (void $\ast$data, int type, void $\ast$event)
\begin{DoxyCompactList}\small\item\em A callback used by the main loop to handle events of a specified type. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add}} (int type, \mbox{\hyperlink{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}{Ecore\+\_\+\+Event\+\_\+\+Handler\+\_\+\+Cb}} func, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Adds an event handler. \end{DoxyCompactList}\item 
\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_gabc9b93070fd6b8ac2f2dd2fc557f2cef}{ecore\+\_\+event\+\_\+handler\+\_\+prepend}} (int type, \mbox{\hyperlink{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}{Ecore\+\_\+\+Event\+\_\+\+Handler\+\_\+\+Cb}} func, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Adds an event handler to the beginning of the handler list. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_ga06b06480c83da219f1118835a1c23a2e}{ecore\+\_\+event\+\_\+handler\+\_\+del}} (\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$event\+\_\+handler)
\begin{DoxyCompactList}\small\item\em Deletes an event handler. \end{DoxyCompactList}\item 
\mbox{\hyperlink{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}{Ecore\+\_\+\+Event}} $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}{ecore\+\_\+event\+\_\+add}} (int type, void $\ast$ev, \mbox{\hyperlink{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}{Ecore\+\_\+\+End\+\_\+\+Cb}} func\+\_\+free, void $\ast$data)
\begin{DoxyCompactList}\small\item\em Adds an event to the event queue. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_gac05faeba0b9dcf8906d744e23ea7aa3b}{ecore\+\_\+event\+\_\+del}} (\mbox{\hyperlink{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}{Ecore\+\_\+\+Event}} $\ast$event)
\begin{DoxyCompactList}\small\item\em Deletes an event from the queue. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_gab378a70725e32b828a734cf3bd01a989}{ecore\+\_\+event\+\_\+handler\+\_\+data\+\_\+get}} (\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$eh)
\begin{DoxyCompactList}\small\item\em Gets the data associated with an \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}}. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_gaf9345a1d588ea72d5d64c7dbe04969f7}{ecore\+\_\+event\+\_\+handler\+\_\+data\+\_\+set}} (\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$eh, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Sets the data associated with an \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}}. \end{DoxyCompactList}\item 
int \mbox{\hyperlink{group__Ecore__Event__Group_ga3fad8d8bfe3776c69d33aff1f056ba89}{ecore\+\_\+event\+\_\+type\+\_\+new}} (void)
\begin{DoxyCompactList}\small\item\em Allocates a new event type id sensibly and returns the new id. \end{DoxyCompactList}\item 
void \mbox{\hyperlink{group__Ecore__Event__Group_ga02391c0cd64135b4121e96cae897969b}{ecore\+\_\+event\+\_\+type\+\_\+flush\+\_\+internal}} (int type,...)
\begin{DoxyCompactList}\small\item\em Forcefully flush all pending type without processing them. \end{DoxyCompactList}\item 
\mbox{\hyperlink{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}{Ecore\+\_\+\+Event\+\_\+\+Filter}} $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_ga8f6dff827b8114aece67111314326f32}{ecore\+\_\+event\+\_\+filter\+\_\+add}} (\mbox{\hyperlink{group__Ecore__Main__Loop__Group_gac4edb7065bb785df0d1a90041380ea76}{Ecore\+\_\+\+Data\+\_\+\+Cb}} func\+\_\+start, \mbox{\hyperlink{group__Ecore__Event__Group_ga0b7b5c494bd8f55a5068786b2caaf6c3}{Ecore\+\_\+\+Filter\+\_\+\+Cb}} func\+\_\+filter, \mbox{\hyperlink{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}{Ecore\+\_\+\+End\+\_\+\+Cb}} func\+\_\+end, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Adds a filter the current event queue. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_ga4fe10195daef6636c3dab6b34fd13a1f}{ecore\+\_\+event\+\_\+filter\+\_\+del}} (\mbox{\hyperlink{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}{Ecore\+\_\+\+Event\+\_\+\+Filter}} $\ast$ef)
\begin{DoxyCompactList}\small\item\em Deletes an event filter. \end{DoxyCompactList}\item 
int \mbox{\hyperlink{group__Ecore__Event__Group_gaf432719ba9654b619d23a20ad036599a}{ecore\+\_\+event\+\_\+current\+\_\+type\+\_\+get}} (void)
\begin{DoxyCompactList}\small\item\em Returns the current event type being handled. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Event__Group_gabdb25394f708ae38b38d30d15c751673}{ecore\+\_\+event\+\_\+current\+\_\+event\+\_\+get}} (void)
\begin{DoxyCompactList}\small\item\em Returns the current event type pointer handled. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Ecore events provide two main features that are of use to those using ecore\+: creating events and being notified of events. 

Those two will usually be used in different contexts, creating events is mainly done by libraries wrapping some system functionality while being notified of events is mainly a necessity of applications.

For a program to be notified of events it\textquotesingle{}s interested in it needs to have a function to process the event and to register that function as the callback to the event, that\textquotesingle{}s all\+: 
\begin{DoxyCode}{0}
\DoxyCodeLine{\mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\_event\_handler\_add}}(EVENT\_TYPE,\ \_my\_event\_handler,\ some\_data);}
\DoxyCodeLine{...}
\DoxyCodeLine{static\ \mbox{\hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\_Bool}}}
\DoxyCodeLine{\_my\_event\_handler(\textcolor{keywordtype}{void}\ *data,\ \textcolor{keywordtype}{int}\ type,\ \textcolor{keywordtype}{void}\ *event)}
\DoxyCodeLine{\{}
\DoxyCodeLine{\ \ \ \textcolor{comment}{//data\ is\ some\_data}}
\DoxyCodeLine{\ \ \ \textcolor{comment}{//event\ is\ provided\ by\ whoever\ created\ the\ event}}
\DoxyCodeLine{\ \ \ \textcolor{comment}{//Do\ really\ cool\ stuff\ with\ event}}
\DoxyCodeLine{\}}

\end{DoxyCode}


One very important thing to note here is the {\ttfamily EVENT\+\_\+\+TYPE}, to register a handler for an event you must know its type before hand. Ecore provides the following events which are emitted in response to POSIX signals(\href{https://en.wikipedia.org/wiki/Signal_\%28computing\%29}{\texttt{ https\+://en.\+wikipedia.\+org/wiki/\+Signal\+\_\+\%28computing\%29}})\+: \begin{DoxyItemize}
\item {\bfseries{ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+USER}} \item {\bfseries{ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+HUP}} \item {\bfseries{ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+POWER}} \item {\bfseries{ECORE\+\_\+\+EVENT\+\_\+\+SIGNAL\+\_\+\+EXIT}} \end{DoxyItemize}
\begin{DoxyWarning}{Warning}
Don\textquotesingle{}t override these using the {\ttfamily signal} or {\ttfamily sigaction} calls. These, however, aren\textquotesingle{}t the only signals one can handle. Many libraries(including ecore modules) have their own signals that can be listened for and handled, to do that one only needs to know the type of the event. This information can be found on the documentation of the library emitting the signal, so, for example, for events related to windowing one would look in \mbox{\hyperlink{group__Ecore__Evas__Group}{Ecore\+\_\+\+Evas wrapper/helper set of functions}}.
\end{DoxyWarning}
Examples of libraries that integrate into ecore\textquotesingle{}s main loop by providing events are \mbox{\hyperlink{group__Ecore__Con__Group}{Ecore\+\_\+\+Con -\/ Connection functions}}, \mbox{\hyperlink{group__Ecore__Evas__Group}{Ecore\+\_\+\+Evas wrapper/helper set of functions}} and \mbox{\hyperlink{group__Ecore__Exe__Group}{Process Spawning Functions}}, amongst others. This usage can be divided into two parts, setup and adding events. The setup is very simple, all that needs doing is getting a type id for the event\+: 
\begin{DoxyCode}{0}
\DoxyCodeLine{\textcolor{keywordtype}{int}\ MY\_EV\_TYPE\ =\ \mbox{\hyperlink{group__Ecore__Event__Group_ga3fad8d8bfe3776c69d33aff1f056ba89}{ecore\_event\_type\_new}}();}

\end{DoxyCode}
 \begin{DoxyNote}{Note}
This variable should be declared in the header since it\textquotesingle{}ll be needed by anyone wishing to register a handler to your event.
\end{DoxyNote}
The complexity of adding of an event to the queue depends on whether that event sends uses {\ttfamily event}, if it doesn\textquotesingle{}t it a one-\/liner\+: 
\begin{DoxyCode}{0}
\DoxyCodeLine{\mbox{\hyperlink{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}{ecore\_event\_add}}(MY\_EV\_TYPE,\ NULL,\ NULL,\ NULL);}

\end{DoxyCode}
 The usage when an {\ttfamily event} is needed is not that much more complex and can be seen in \mbox{\hyperlink{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}{ecore\+\_\+event\+\_\+add}}.

Examples that deals with events\+: \begin{DoxyItemize}
\item \mbox{\hyperlink{ecore_event_example_01_c}{Handling events example}} \item \mbox{\hyperlink{ecore_event_example_02_c}{ecore events and handlers -\/ Setup and use}} \end{DoxyItemize}


\doxysubsection{Macro Definition Documentation}
\mbox{\Hypertarget{group__Ecore__Event__Group_gab7200780b0a2b7fca55f36a90119f0ce}\label{group__Ecore__Event__Group_gab7200780b0a2b7fca55f36a90119f0ce}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_type\_flush@{ecore\_event\_type\_flush}}
\index{ecore\_event\_type\_flush@{ecore\_event\_type\_flush}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_type\_flush}{ecore\_event\_type\_flush}}
{\footnotesize\ttfamily \#define ecore\+\_\+event\+\_\+type\+\_\+flush(\begin{DoxyParamCaption}\item[{}]{... }\end{DoxyParamCaption})~  \mbox{\hyperlink{group__Ecore__Event__Group_ga02391c0cd64135b4121e96cae897969b}{ecore\+\_\+event\+\_\+type\+\_\+flush\+\_\+internal}}(\+\_\+\+\_\+\+VA\+\_\+\+ARGS\+\_\+\+\_\+, \mbox{\hyperlink{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}{ECORE\+\_\+\+EVENT\+\_\+\+NONE}});}



Forcefully flush all pending type without processing them. 


\begin{DoxyParams}{Parameters}
{\em ...} & Serie of Ecore\+\_\+\+Event.\\
\hline
\end{DoxyParams}
This function is to be called before calling \mbox{\hyperlink{group__Ecore__Init__Group_ga768298b932f18d7e7593a447493e5cde}{ecore\+\_\+shutdown()}} if any event has still a chance to be in the ecore event queue. 

\doxysubsection{Function Documentation}
\mbox{\Hypertarget{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}\label{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_handler\_add@{ecore\_event\_handler\_add}}
\index{ecore\_event\_handler\_add@{ecore\_event\_handler\_add}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_handler\_add()}{ecore\_event\_handler\_add()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$ ecore\+\_\+event\+\_\+handler\+\_\+add (\begin{DoxyParamCaption}\item[{int}]{type,  }\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}{Ecore\+\_\+\+Event\+\_\+\+Handler\+\_\+\+Cb}}}]{func,  }\item[{const void $\ast$}]{data }\end{DoxyParamCaption})}



Adds an event handler. 


\begin{DoxyParams}{Parameters}
{\em type} & The type of the event this handler will get called for \\
\hline
{\em func} & The function to call when the event is found in the queue \\
\hline
{\em data} & A data pointer to pass to the called function {\ttfamily func} \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A new Event handler, or {\ttfamily NULL} on failure.
\end{DoxyReturn}
Add an event handler to the list of handlers. This will, on success, return a handle to the event handler object that was created, that can be used later to remove the handler using \mbox{\hyperlink{group__Ecore__Event__Group_ga06b06480c83da219f1118835a1c23a2e}{ecore\+\_\+event\+\_\+handler\+\_\+del()}}. The {\ttfamily type} parameter is the integer of the event type that will trigger this callback to be called. The callback {\ttfamily func} is called when this event is processed and will be passed the event type, a pointer to the private event structure that is specific to that event type, and a data pointer that is provided in this call as the {\ttfamily data} parameter.

When the callback {\ttfamily func} is called, it must return {\ttfamily 1} or {\ttfamily 0}. If it returns {\ttfamily 1} (or {\ttfamily ECORE\+\_\+\+CALLBACK\+\_\+\+PASS\+\_\+\+ON}), It will keep being called as per normal, for each handler set up for that event type. If it returns {\ttfamily 0} (or {\ttfamily ECORE\+\_\+\+CALLBACK\+\_\+\+DONE}), it will cease processing handlers for that particular event, so all handler set to handle that event type that have not already been called, will not be. \begin{Desc}
\item[Examples]\par
\mbox{\hyperlink{ecore_con_client_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_server_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_server_simple_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+simple\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_url_cookies_example_8c-example}{ecore\+\_\+con\+\_\+url\+\_\+cookies\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_url_download_example_8c-example}{ecore\+\_\+con\+\_\+url\+\_\+download\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_con_url_headers_example_8c-example}{ecore\+\_\+con\+\_\+url\+\_\+headers\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_event_example_01_8c-example}{ecore\+\_\+event\+\_\+example\+\_\+01.\+c}}, \mbox{\hyperlink{ecore_event_example_02_8c-example}{ecore\+\_\+event\+\_\+example\+\_\+02.\+c}}, \mbox{\hyperlink{ecore_exe_example_8c-example}{ecore\+\_\+exe\+\_\+example.\+c}}, \mbox{\hyperlink{ecore_idler_example_8c-example}{ecore\+\_\+idler\+\_\+example.\+c}}, \mbox{\hyperlink{emotion_test_main_8c-example}{emotion\+\_\+test\+\_\+main.\+c}}, and \mbox{\hyperlink{win_example_8c-example}{win\+\_\+example.\+c}}.\end{Desc}


Referenced by \mbox{\hyperlink{group__Ecore__Drm2__Device__Group_gadd02bec97fc93262fa6c3581cc92534f}{ecore\+\_\+drm2\+\_\+device\+\_\+open()}}, \mbox{\hyperlink{group__Ecore__Drm__Tty__Group_ga73153bb0b7118993ceddaf8e19d0fbc1}{ecore\+\_\+drm\+\_\+tty\+\_\+open()}}, \mbox{\hyperlink{group__Elm__Icon_gababcfd77a35c49ed5e988cda64cbf694}{elm\+\_\+icon\+\_\+thumb\+\_\+set()}}, \mbox{\hyperlink{group__Elm__General_ga0c2e80e13f4855004f7ccb61e891aef0}{elm\+\_\+init()}}, \mbox{\hyperlink{group__Elm__General_gab31fb3af2f25295fea1eb05f69724eb5}{elm\+\_\+quicklaunch\+\_\+init()}}, and \mbox{\hyperlink{group__Elput__Manager__Group_ga8c5287fb689b4f7be28a677500be950d}{elput\+\_\+manager\+\_\+open()}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_gabc9b93070fd6b8ac2f2dd2fc557f2cef}\label{group__Ecore__Event__Group_gabc9b93070fd6b8ac2f2dd2fc557f2cef}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_handler\_prepend@{ecore\_event\_handler\_prepend}}
\index{ecore\_event\_handler\_prepend@{ecore\_event\_handler\_prepend}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_handler\_prepend()}{ecore\_event\_handler\_prepend()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$ ecore\+\_\+event\+\_\+handler\+\_\+prepend (\begin{DoxyParamCaption}\item[{int}]{type,  }\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga64b4df04cbafda481593d0bc29617c6d}{Ecore\+\_\+\+Event\+\_\+\+Handler\+\_\+\+Cb}}}]{func,  }\item[{const void $\ast$}]{data }\end{DoxyParamCaption})}



Adds an event handler to the beginning of the handler list. 


\begin{DoxyParams}{Parameters}
{\em type} & The type of the event this handler will get called for \\
\hline
{\em func} & The function to call when the event is found in the queue \\
\hline
{\em data} & A data pointer to pass to the called function {\ttfamily func} \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A new Event handler, or {\ttfamily NULL} on failure.
\end{DoxyReturn}
This function is identical to \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add()}} except that it creates the handler at the start of the list. Do not use this function. \begin{DoxySince}{Since}
1.\+21 
\end{DoxySince}
\mbox{\Hypertarget{group__Ecore__Event__Group_ga06b06480c83da219f1118835a1c23a2e}\label{group__Ecore__Event__Group_ga06b06480c83da219f1118835a1c23a2e}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_handler\_del@{ecore\_event\_handler\_del}}
\index{ecore\_event\_handler\_del@{ecore\_event\_handler\_del}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_handler\_del()}{ecore\_event\_handler\_del()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+handler\+\_\+del (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$}]{event\+\_\+handler }\end{DoxyParamCaption})}



Deletes an event handler. 


\begin{DoxyParams}{Parameters}
{\em event\+\_\+handler} & Event handler handle to delete \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Data passed to handler
\end{DoxyReturn}
Delete a specified event handler from the handler list. On success this will delete the event handler and return the pointer passed as {\ttfamily data} when the handler was added by \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add()}}. On failure {\ttfamily NULL} will be returned. Once a handler is deleted it will no longer be called. 

Referenced by \mbox{\hyperlink{group__Ecore__Drm2__Device__Group_ga723ea01676711266a102ea539971795e}{ecore\+\_\+drm2\+\_\+device\+\_\+close()}}, \mbox{\hyperlink{group__Ecore__Drm__Tty__Group_gab0d1199e4346591a7236d5fecd3c3558}{ecore\+\_\+drm\+\_\+tty\+\_\+close()}}, \mbox{\hyperlink{group__Elm__General_ga9fcc62ef962c1b166c693cfd6f2372e4}{elm\+\_\+quicklaunch\+\_\+shutdown()}}, \mbox{\hyperlink{group__Elm__General_ga9de9b3690cc9d500e4576e0f086a099a}{elm\+\_\+shutdown()}}, and \mbox{\hyperlink{group__Elput__Manager__Group_gafe51840dc0d72a69bd5fd857a72d7bb1}{elput\+\_\+manager\+\_\+close()}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}\label{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_add@{ecore\_event\_add}}
\index{ecore\_event\_add@{ecore\_event\_add}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_add()}{ecore\_event\_add()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}{Ecore\+\_\+\+Event}} $\ast$ ecore\+\_\+event\+\_\+add (\begin{DoxyParamCaption}\item[{int}]{type,  }\item[{void $\ast$}]{ev,  }\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}{Ecore\+\_\+\+End\+\_\+\+Cb}}}]{func\+\_\+free,  }\item[{void $\ast$}]{data }\end{DoxyParamCaption})}



Adds an event to the event queue. 


\begin{DoxyParams}{Parameters}
{\em type} & The event type to add to the end of the event queue \\
\hline
{\em ev} & The data structure passed as {\ttfamily event} to event handlers \\
\hline
{\em func\+\_\+free} & The function to be called to free {\itshape ev} \\
\hline
{\em data} & The data pointer to be passed to the free function \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A Handle for that event on success, otherwise NULL
\end{DoxyReturn}
If it succeeds, an event of type {\itshape type} will be added to the queue for processing by event handlers added by \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add()}}. The {\itshape ev} parameter will be passed as the {\ttfamily event} parameter of the handler. When the event is no longer needed, {\itshape func\+\_\+free} will be called and passed {\itshape ev} for cleaning up. If {\ttfamily func\+\_\+free} is NULL, free() will be called with the private structure pointer. \begin{Desc}
\item[Examples]\par
\mbox{\hyperlink{ecore_event_example_02_8c-example}{ecore\+\_\+event\+\_\+example\+\_\+02.\+c}}, and \mbox{\hyperlink{ecore_idler_example_8c-example}{ecore\+\_\+idler\+\_\+example.\+c}}.\end{Desc}


References \mbox{\hyperlink{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}{ECORE\+\_\+\+EVENT\+\_\+\+NONE}}.



Referenced by \mbox{\hyperlink{group__Ecore__IMF__Context__Module__Group_ga6f45ccdde23d5281b91f08e56aeb8916}{ecore\+\_\+imf\+\_\+context\+\_\+commit\+\_\+event\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__IMF__Context__Module__Group_ga00f0b451fcb79d2ad0fcda24eed557ee}{ecore\+\_\+imf\+\_\+context\+\_\+delete\+\_\+surrounding\+\_\+event\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__IMF__Context__Module__Group_gabdbcb39d485cf961e0c7f04777e7e041}{ecore\+\_\+imf\+\_\+context\+\_\+preedit\+\_\+changed\+\_\+event\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__IMF__Context__Module__Group_gad67ac4e708b7dccad3bd46437b562009}{ecore\+\_\+imf\+\_\+context\+\_\+preedit\+\_\+end\+\_\+event\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__IMF__Context__Module__Group_ga24102021df9910871fd69a9aeb23cabb}{ecore\+\_\+imf\+\_\+context\+\_\+preedit\+\_\+start\+\_\+event\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__Job__Group_ga859b3807977b215b7589f5b61dbf9ac2}{ecore\+\_\+job\+\_\+add()}}, \mbox{\hyperlink{group__Ecore__System__Events_gad8518e0da15a192d387699857446de77}{ecore\+\_\+memory\+\_\+state\+\_\+set()}}, \mbox{\hyperlink{group__Ecore__System__Events_ga5fef957187dc452dfd745df5f8009116}{ecore\+\_\+power\+\_\+state\+\_\+set()}}, \mbox{\hyperlink{Ecore__Sdl_8h_a02070a2ecd3d48bc86b3d9db410521ed}{ecore\+\_\+sdl\+\_\+feed\+\_\+events()}}, \mbox{\hyperlink{group__Ecore__Wl2__Dnd__Group_gab160a1d2bec2091a6f445c1e51433a24}{ecore\+\_\+wl2\+\_\+dnd\+\_\+drag\+\_\+end()}}, \mbox{\hyperlink{group__Ecore__Wl__Dnd__Group_gab78828c16c885be5d416bc1dabd4133c}{ecore\+\_\+wl\+\_\+dnd\+\_\+drag\+\_\+end()}}, and \mbox{\hyperlink{group__Elm__General_ga7a05f37fd3a019da5e26c5fc91fcd937}{elm\+\_\+policy\+\_\+set()}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_gac05faeba0b9dcf8906d744e23ea7aa3b}\label{group__Ecore__Event__Group_gac05faeba0b9dcf8906d744e23ea7aa3b}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_del@{ecore\_event\_del}}
\index{ecore\_event\_del@{ecore\_event\_del}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_del()}{ecore\_event\_del()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+del (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga3df1c1b99f44f47e791c89556e925b9d}{Ecore\+\_\+\+Event}} $\ast$}]{event }\end{DoxyParamCaption})}



Deletes an event from the queue. 


\begin{DoxyParams}{Parameters}
{\em event} & The event handle to delete \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The data pointer originally set for the event free function
\end{DoxyReturn}
This deletes the event {\ttfamily event} from the event queue, and returns the {\ttfamily data} parameter originally set when adding it with \mbox{\hyperlink{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}{ecore\+\_\+event\+\_\+add()}}. This does not immediately call the free function, and it may be called later on cleanup, and so if the free function depends on the data pointer to work, you should defer cleaning of this till the free function is called later. 

Referenced by \mbox{\hyperlink{group__Ecore__Job__Group_ga6baa274d218948aaaeaaa19cd8b094f4}{ecore\+\_\+job\+\_\+del()}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_gab378a70725e32b828a734cf3bd01a989}\label{group__Ecore__Event__Group_gab378a70725e32b828a734cf3bd01a989}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_handler\_data\_get@{ecore\_event\_handler\_data\_get}}
\index{ecore\_event\_handler\_data\_get@{ecore\_event\_handler\_data\_get}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_handler\_data\_get()}{ecore\_event\_handler\_data\_get()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+handler\+\_\+data\+\_\+get (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$}]{eh }\end{DoxyParamCaption})}



Gets the data associated with an \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}}. 


\begin{DoxyParams}{Parameters}
{\em eh} & The event handler \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The data
\end{DoxyReturn}
This function returns the data previously associated with {\ttfamily eh} by \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add()}}. \mbox{\Hypertarget{group__Ecore__Event__Group_gaf9345a1d588ea72d5d64c7dbe04969f7}\label{group__Ecore__Event__Group_gaf9345a1d588ea72d5d64c7dbe04969f7}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_handler\_data\_set@{ecore\_event\_handler\_data\_set}}
\index{ecore\_event\_handler\_data\_set@{ecore\_event\_handler\_data\_set}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_handler\_data\_set()}{ecore\_event\_handler\_data\_set()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+handler\+\_\+data\+\_\+set (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}} $\ast$}]{eh,  }\item[{const void $\ast$}]{data }\end{DoxyParamCaption})}



Sets the data associated with an \mbox{\hyperlink{group__Ecore__Event__Group_ga252a2566c9c7c9094964ab8e157f0521}{Ecore\+\_\+\+Event\+\_\+\+Handler}}. 


\begin{DoxyParams}{Parameters}
{\em eh} & The event handler \\
\hline
{\em data} & The data to associate \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The previous data
\end{DoxyReturn}
This function sets {\ttfamily data} to {\ttfamily eh} and returns the old data pointer which was previously associated with {\ttfamily eh} by \mbox{\hyperlink{group__Ecore__Event__Group_ga886c90c3f917f87b3b4c931adcbc41c5}{ecore\+\_\+event\+\_\+handler\+\_\+add()}}. \begin{Desc}
\item[Examples]\par
\mbox{\hyperlink{ecore_event_example_02_8c-example}{ecore\+\_\+event\+\_\+example\+\_\+02.\+c}}.\end{Desc}
\mbox{\Hypertarget{group__Ecore__Event__Group_ga3fad8d8bfe3776c69d33aff1f056ba89}\label{group__Ecore__Event__Group_ga3fad8d8bfe3776c69d33aff1f056ba89}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_type\_new@{ecore\_event\_type\_new}}
\index{ecore\_event\_type\_new@{ecore\_event\_type\_new}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_type\_new()}{ecore\_event\_type\_new()}}
{\footnotesize\ttfamily int ecore\+\_\+event\+\_\+type\+\_\+new (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Allocates a new event type id sensibly and returns the new id. 

\begin{DoxyReturn}{Returns}
A new event type id.
\end{DoxyReturn}
This function allocates a new event type id and returns it. Once an event type has been allocated it can never be de-\/allocated during the life of the program. There is no guarantee of the contents of this event ID, or how it is calculated, except that the ID will be unique to the current instance of the process. \begin{Desc}
\item[Examples]\par
\mbox{\hyperlink{ecore_event_example_02_8c-example}{ecore\+\_\+event\+\_\+example\+\_\+02.\+c}}, and \mbox{\hyperlink{ecore_idler_example_8c-example}{ecore\+\_\+idler\+\_\+example.\+c}}.\end{Desc}


Referenced by \mbox{\hyperlink{group__Ecore__Con__Url__Group_ga96388997453269f58bde7873811af6d5}{ecore\+\_\+con\+\_\+url\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Drm2__Init__Group_gac80f615f0768a0a79e3c71e9a80577eb}{ecore\+\_\+drm2\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Drm__Init__Group_gae2c58e2992ce9af065417ec998202546}{ecore\+\_\+drm\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Input__Group_gac7674e92b0aa4d30a9f6ebb7a7ce11d6}{ecore\+\_\+event\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__IMF__Lib__Group_gade7d780e03136d2799e6d212d188184a}{ecore\+\_\+imf\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__IPC__Group_gade1baa6a3e79dd7c9bd6244dad0e6571}{ecore\+\_\+ipc\+\_\+init()}}, \mbox{\hyperlink{Ecore__Sdl_8h_aee685db146c11d420fca59f450de2d5d}{ecore\+\_\+sdl\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Win32__Group_ga3219c174d44558bb46104540852a8d34}{ecore\+\_\+win32\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Wl2__Init__Group_gad439e46a49f2c1175b572dda9a002254}{ecore\+\_\+wl2\+\_\+init()}}, \mbox{\hyperlink{group__Ecore__Wl__Init__Group_gaf158fc255ed0fbbe4721475a87d86828}{ecore\+\_\+wl\+\_\+init()}}, \mbox{\hyperlink{group__Elm__General_ga0c2e80e13f4855004f7ccb61e891aef0}{elm\+\_\+init()}}, \mbox{\hyperlink{group__Elm__Thumb_gaf60949008673f1ec68aa33138663ac57}{elm\+\_\+need\+\_\+ethumb()}}, \mbox{\hyperlink{group__Elm__General_gab31fb3af2f25295fea1eb05f69724eb5}{elm\+\_\+quicklaunch\+\_\+init()}}, and \mbox{\hyperlink{group__Elput__Init__Group_gabde718edc099f32cae26bb58edc424b7}{elput\+\_\+init()}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_ga02391c0cd64135b4121e96cae897969b}\label{group__Ecore__Event__Group_ga02391c0cd64135b4121e96cae897969b}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_type\_flush\_internal@{ecore\_event\_type\_flush\_internal}}
\index{ecore\_event\_type\_flush\_internal@{ecore\_event\_type\_flush\_internal}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_type\_flush\_internal()}{ecore\_event\_type\_flush\_internal()}}
{\footnotesize\ttfamily void ecore\+\_\+event\+\_\+type\+\_\+flush\+\_\+internal (\begin{DoxyParamCaption}\item[{int}]{type,  }\item[{}]{... }\end{DoxyParamCaption})}



Forcefully flush all pending type without processing them. 


\begin{DoxyParams}{Parameters}
{\em type} & Ecore\+\_\+\+Event. \\
\hline
{\em ...} & Serie of Ecore\+\_\+\+Event finished by ECORE\+\_\+\+EVENT\+\_\+\+NONE.\\
\hline
\end{DoxyParams}
This function is to be called before calling \mbox{\hyperlink{group__Ecore__Init__Group_ga768298b932f18d7e7593a447493e5cde}{ecore\+\_\+shutdown()}} if any event has still a chance to be in the ecore event queue. 

References \mbox{\hyperlink{group__Ecore__Event__Group_ga2b6dc74bf55d27f7a069e6d976808ef7}{ECORE\+\_\+\+EVENT\+\_\+\+NONE}}.

\mbox{\Hypertarget{group__Ecore__Event__Group_ga8f6dff827b8114aece67111314326f32}\label{group__Ecore__Event__Group_ga8f6dff827b8114aece67111314326f32}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_filter\_add@{ecore\_event\_filter\_add}}
\index{ecore\_event\_filter\_add@{ecore\_event\_filter\_add}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_filter\_add()}{ecore\_event\_filter\_add()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}{Ecore\+\_\+\+Event\+\_\+\+Filter}} $\ast$ ecore\+\_\+event\+\_\+filter\+\_\+add (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Main__Loop__Group_gac4edb7065bb785df0d1a90041380ea76}{Ecore\+\_\+\+Data\+\_\+\+Cb}}}]{func\+\_\+start,  }\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga0b7b5c494bd8f55a5068786b2caaf6c3}{Ecore\+\_\+\+Filter\+\_\+\+Cb}}}]{func\+\_\+filter,  }\item[{\mbox{\hyperlink{group__Ecore__Event__Group_ga1d6806e0a537d3e364d1094e91db4cb7}{Ecore\+\_\+\+End\+\_\+\+Cb}}}]{func\+\_\+end,  }\item[{const void $\ast$}]{data }\end{DoxyParamCaption})}



Adds a filter the current event queue. 


\begin{DoxyParams}{Parameters}
{\em func\+\_\+start} & Function to call just before filtering and return data \\
\hline
{\em func\+\_\+filter} & Function to call on each event \\
\hline
{\em func\+\_\+end} & Function to call after the queue has been filtered \\
\hline
{\em data} & Data to pass to the filter functions \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A filter handle on success, {\ttfamily NULL} otherwise.
\end{DoxyReturn}
Adds a callback to filter events from the event queue. Filters are called on the queue just before Event handler processing to try and remove redundant events. Just as processing is about to start {\itshape func\+\_\+start} is called and passed the {\itshape data} pointer, the return value of this functions is passed to {\itshape func\+\_\+filter} as loop\+\_\+data. {\itshape func\+\_\+filter} is also passed {\itshape data} and the event type and event structure. If this {\itshape func\+\_\+filter} returns {\ttfamily EINA\+\_\+\+FALSE}, the event is removed from the queue, if it returns {\ttfamily EINA\+\_\+\+TRUE}, the event is kept. When processing is finished {\ttfamily func\+\_\+end} is called and is passed the loop\+\_\+data(returned by {\ttfamily func\+\_\+start}) and {\ttfamily data} pointer to clean up. \mbox{\Hypertarget{group__Ecore__Event__Group_ga4fe10195daef6636c3dab6b34fd13a1f}\label{group__Ecore__Event__Group_ga4fe10195daef6636c3dab6b34fd13a1f}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_filter\_del@{ecore\_event\_filter\_del}}
\index{ecore\_event\_filter\_del@{ecore\_event\_filter\_del}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_filter\_del()}{ecore\_event\_filter\_del()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+filter\+\_\+del (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Event__Group_gab7f572080436ad68d75e8eb4b7cbab45}{Ecore\+\_\+\+Event\+\_\+\+Filter}} $\ast$}]{ef }\end{DoxyParamCaption})}



Deletes an event filter. 


\begin{DoxyParams}{Parameters}
{\em ef} & The event filter handle \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The data set for the filter on success, {\ttfamily NULL} otherwise.
\end{DoxyReturn}
Delete a filter that has been added by its {\ttfamily ef} handle. \mbox{\Hypertarget{group__Ecore__Event__Group_gaf432719ba9654b619d23a20ad036599a}\label{group__Ecore__Event__Group_gaf432719ba9654b619d23a20ad036599a}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_current\_type\_get@{ecore\_event\_current\_type\_get}}
\index{ecore\_event\_current\_type\_get@{ecore\_event\_current\_type\_get}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_current\_type\_get()}{ecore\_event\_current\_type\_get()}}
{\footnotesize\ttfamily int ecore\+\_\+event\+\_\+current\+\_\+type\+\_\+get (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Returns the current event type being handled. 

\begin{DoxyReturn}{Returns}
The current event type being handled if inside a handler callback, {\ttfamily ECORE\+\_\+\+EVENT\+\_\+\+NONE} otherwise.
\end{DoxyReturn}
If the program is currently inside an Ecore event handler callback this will return the type of the current event being processed.

This is useful when certain Ecore modules such as Ecore\+\_\+\+Evas \char`\"{}swallow\char`\"{} events and not all the original information is passed on. In special cases this extra information may be useful or needed and using this call can let the program know if the event type being handled is one it wants to get more information about. \mbox{\Hypertarget{group__Ecore__Event__Group_gabdb25394f708ae38b38d30d15c751673}\label{group__Ecore__Event__Group_gabdb25394f708ae38b38d30d15c751673}} 
\index{Ecore Event functions@{Ecore Event functions}!ecore\_event\_current\_event\_get@{ecore\_event\_current\_event\_get}}
\index{ecore\_event\_current\_event\_get@{ecore\_event\_current\_event\_get}!Ecore Event functions@{Ecore Event functions}}
\doxysubsubsection{\texorpdfstring{ecore\_event\_current\_event\_get()}{ecore\_event\_current\_event\_get()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+event\+\_\+current\+\_\+event\+\_\+get (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Returns the current event type pointer handled. 

\begin{DoxyReturn}{Returns}
The current event pointer being handled if inside a handler callback, {\ttfamily NULL} otherwise.
\end{DoxyReturn}
If the program is currently inside an Ecore event handler callback this will return the pointer of the current event being processed.

This is useful when certain Ecore modules such as Ecore\+\_\+\+Evas \char`\"{}swallow\char`\"{} events and not all the original information is passed on. In special cases this extra information may be useful or needed and using this call can let the program access the event data if the type of the event is handled by the program. 