Enlightenment CVS committal
Author : moom
Project : e17
Module : proto
Dir : e17/proto/etk/src/engines/ecore_evas_x11
Modified Files:
ecore_evas_x11.c
Log Message:
* Move ETK_INSIDE() macro to etk_utils
* Add a shutdown() method to the engine API
===================================================================
RCS file: /cvs/e/e17/proto/etk/src/engines/ecore_evas_x11/ecore_evas_x11.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- ecore_evas_x11.c 27 Jul 2006 17:22:03 -0000 1.5
+++ ecore_evas_x11.c 27 Jul 2006 18:19:28 -0000 1.6
@@ -18,8 +18,6 @@
#include "Etk_Engine_Ecore_Evas.h"
#include "Etk_Engine_Ecore_Evas_X11.h"
-#define ETK_INSIDE(x, y, xx, yy, ww, hh) (((x) < ((xx) + (ww))) && ((y) <
((yy) + (hh))) && ((x) >= (xx)) && ((y) >= (yy)))
-
/* Engine specific data for Etk_Window
* We do this to shorten the name for internal use
*/
@@ -40,7 +38,10 @@
static Evas_List *_popup_window_popped_windows = NULL;
/* General engine functions */
-Etk_Engine *engine_init();
+Etk_Engine *engine_open();
+
+static Etk_Bool _engine_init();
+static void _engine_shutdown();
/* Etk_Window functions */
static void _window_constructor(Etk_Window *window);
@@ -128,6 +129,9 @@
NULL, /* super (parent) engine */
NULL, /* DL handle */
+ _engine_init,
+ _engine_shutdown,
+
_window_constructor,
_window_destructor,
NULL, /* window_show */
@@ -190,12 +194,27 @@
_selection_clear
};
-Etk_Engine * engine_init()
+Etk_Engine *engine_open()
{
engine_info.engine_data = NULL;
engine_info.engine_name = strdup("ecore_evas_x11");
etk_engine_inherit_from(&engine_info, "ecore_evas");
return &engine_info;
+}
+
+static Etk_Bool _engine_init()
+{
+ if (!ecore_x_init(NULL))
+ {
+ ETK_WARNING("Ecore_X initialization failed!");
+ return ETK_FALSE;
+ }
+ return ETK_TRUE;
+}
+
+static void _engine_shutdown()
+{
+ ecore_x_shutdown();
}
static void _window_constructor(Etk_Window *window)
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs