Enlightenment CVS committal

Author  : raster
Project : e17
Module  : libs/ecore

Dir     : e17/libs/ecore/src/lib/ecore


Modified Files:
      Tag: SPLIT
        Ecore.h ecore_events.c 


Log Message:


ecore events code needed for edje commit

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore/Attic/Ecore.h,v
retrieving revision 1.1.2.7
retrieving revision 1.1.2.8
diff -u -3 -r1.1.2.7 -r1.1.2.8
--- Ecore.h     8 Apr 2003 08:03:19 -0000       1.1.2.7
+++ Ecore.h     8 Jul 2003 04:26:08 -0000       1.1.2.8
@@ -88,6 +88,9 @@
    int                  ecore_event_type_new(void);
    Ecore_Event_Filter  *ecore_event_filter_add(void * (*func_start) (void *data), int 
(*func_filter) (void *data, void *loop_data, int type, void *event), void (*func_end) 
(void *data, void *loop_data), const void *data);
    void                *ecore_event_filter_del(Ecore_Event_Filter *ef);
+   int                  ecore_event_current_type_get(void);
+   void                *ecore_event_current_event_get(void);
+       
        
 
    Ecore_Exe *ecore_exe_run(const char *exe_cmd, const void *data);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore/Attic/ecore_events.c,v
retrieving revision 1.1.2.13
retrieving revision 1.1.2.14
diff -u -3 -r1.1.2.13 -r1.1.2.14
--- ecore_events.c      8 Apr 2003 08:03:20 -0000       1.1.2.13
+++ ecore_events.c      8 Jul 2003 04:26:08 -0000       1.1.2.14
@@ -12,6 +12,10 @@
 
 static int                  event_id_max = ECORE_EVENT_COUNT;
 
+static int                  ecore_raw_event_type = ECORE_EVENT_NONE;
+static void                *ecore_raw_event_event =  NULL;
+
+
 /**
  * Add an event handler.
  * @param type The type of the event this handler will get called for
@@ -249,6 +253,48 @@
    return ef->data;
 }
 
+/**
+ * Return the current event type being handled.
+ * @return The current event type being handled if inside a handler callback
+ * 
+ * If the program is currently inside an Ecore event handler callback this
+ * will return the type of the current event being processed. If Ecore is
+ * not inside an event handler, ECORE_EVENT_NONE is returned.
+ * 
+ * This is useful when certain Ecore modules such as Ecore_Evas "swallow"
+ * 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.
+ * <hr><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>
+ */
+int
+ecore_event_current_type_get(void)
+{
+   return ecore_raw_event_type;
+}
+
+/**
+ * Return the current event type pointer handled.
+ * @return The current event pointer being handled if inside a handler callback
+ * 
+ * If the program is currently inside an Ecore event handler callback this
+ * will return the pointer of the current event being processed. If Ecore is
+ * not inside an event handler, NULL will be returned.
+ * 
+ * This is useful when certain Ecore modules such as Ecore_Evas "swallow"
+ * 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.
+ * <hr><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>
+ */
+void *
+ecore_event_current_event_get(void)
+{
+   return ecore_raw_event_event;
+}
+
 void
 _ecore_event_shutdown(void)
 {
@@ -375,6 +421,8 @@
        e = (Ecore_Event *)l;
        if (!e->delete_me)
          {
+            ecore_raw_event_type = e->type;
+            ecore_raw_event_event = e->event;
             for (ll = (Ecore_List *)event_handlers; ll; ll = ll->next)
               {
                  Ecore_Event_Handler *eh;
@@ -389,6 +437,8 @@
                         }
                    }
               }
+            ecore_raw_event_type = ECORE_EVENT_NONE;
+            ecore_raw_event_event = NULL;
          }
      }
    while (events) _ecore_event_del(events);




-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to