Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/ecore
Dir : e17/libs/ecore/src/bin
Modified Files:
Tag: SPLIT
ecore_test.c
Log Message:
enough of ecore x module to now pop up and show a window... and get some
events. :)
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/bin/Attic/ecore_test.c,v
retrieving revision 1.1.2.8
retrieving revision 1.1.2.9
diff -u -3 -r1.1.2.8 -r1.1.2.9
--- ecore_test.c 25 Jan 2003 02:56:14 -0000 1.1.2.8
+++ ecore_test.c 4 Feb 2003 04:18:55 -0000 1.1.2.9
@@ -6,6 +6,7 @@
#include <fcntl.h>
double start_time = 0;
+Window win = 0;
void
job_call(void *data)
@@ -120,46 +121,6 @@
return 1;
}
-void
-x_init(void)
-{
- Display *display;
- XClassHint *xch;
- XSetWindowAttributes att;
- Window win;
-
- display = ecore_x_display_get();
- att.background_pixmap = None;
- att.colormap = DefaultColormap(display, DefaultScreen(display));
- att.border_pixel = 0;
- att.event_mask =
- ButtonPressMask |
- ButtonReleaseMask |
- EnterWindowMask |
- LeaveWindowMask |
- PointerMotionMask |
- ExposureMask |
- StructureNotifyMask |
- KeyPressMask |
- KeyReleaseMask;
- win = XCreateWindow(display,
- RootWindow(display, DefaultScreen(display)),
- 0, 0, 160, 160, 0,
- DefaultDepth(display, DefaultScreen(display)),
- InputOutput,
- DefaultVisual(display, DefaultScreen(display)),
- CWColormap | CWBorderPixel | CWEventMask | CWBackPixmap,
- &att);
- XStoreName(display, win, "Ecore Test Program");
- xch = XAllocClassHint();
- xch->res_name = "Main";
- xch->res_class = "Ecore_Demo";
- XSetClassHint(display, win, xch);
- XFree(xch);
- XMapWindow(display, win);
- XSync(display, False);
-}
-
int
main(int argc, const char **argv)
{
@@ -169,8 +130,11 @@
ecore_app_args_set(argc, argv);
if (!ecore_x_init(NULL)) return -1;
-
- x_init();
+
+ win = ecore_x_window_new(0, 0, 0, 240, 320);
+ ecore_x_window_prop_title_set(win, "Ecore Test Program");
+ ecore_x_window_prop_name_class_set(win, "ecore_test", "main");
+ ecore_x_window_show(win);
ecore_idle_enterer_add(idle_enterer, NULL);
// ecore_idler_add(idler, NULL);
-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs