Enlightenment CVS committal

Author  : dj2
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src/engines/evas_buffer


Modified Files:
        ewl_engine_evas_buffer.c 


Log Message:
- Split the engine function array into three smaller arrays. 
  - One for window functions. 
  - One for canvas functions.
  - One for theme functions.

- This should make it easier to implement engines as you can leave the
  entire array NULL if you don't want to implement the given type of
  functions.

===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/engines/evas_buffer/ewl_engine_evas_buffer.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- ewl_engine_evas_buffer.c    1 Oct 2006 01:19:09 -0000       1.2
+++ ewl_engine_evas_buffer.c    12 Oct 2006 21:41:17 -0000      1.3
@@ -11,20 +11,12 @@
 static int ee_init(Ewl_Engine *engine);
 static void ee_shutdown(Ewl_Engine *engine);
 
-static Ewl_Engine_Info engine_funcs = {
+static void *canvas_funcs[EWL_ENGINE_CANVAS_MAX] = 
        {
-               ee_init,
-               ee_shutdown,
-               NULL, NULL, NULL, NULL,
-               NULL, NULL, NULL, NULL,
-               NULL, NULL, NULL, NULL,
-               NULL, NULL, NULL, NULL,
-               NULL, NULL, NULL, NULL,
-               NULL, NULL, NULL,
                ee_canvas_setup,
-               ee_canvas_output_set
-       }
-};
+               ee_canvas_output_set, 
+               NULL, NULL, NULL
+       };
 
 Ecore_DList *
 ewl_engine_dependancies(void)
@@ -62,11 +54,18 @@
 static int
 ee_init(Ewl_Engine *engine)
 {
+       Ewl_Engine_Info *info;
+
        DENTER_FUNCTION(DLEVEL_STABLE);
        DCHECK_PARAM_PTR_RET("engine", engine, TRUE);
 
+       info = NEW(Ewl_Engine_Info, 1);
+       info->init = ee_init;
+       info->shutdown = ee_shutdown;
+       info->hooks.canvas = canvas_funcs;
+
        engine->name = strdup("evas_buffer");
-       engine->functions = &engine_funcs;
+       engine->functions = info;
 
        DRETURN_INT(TRUE, DLEVEL_STABLE);
 }



-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to