Enlightenment CVS committal Author : tilman Project : misc Module : enthrall
Dir : misc/enthrall/src Modified Files: enthrall.c Log Message: configurable pointer image (morlenxus) =================================================================== RCS file: /cvs/e/misc/enthrall/src/enthrall.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -3 -r1.3 -r1.4 --- enthrall.c 18 Aug 2006 17:17:01 -0000 1.3 +++ enthrall.c 18 Aug 2006 17:22:47 -0000 1.4 @@ -1,5 +1,5 @@ /* - * $Id: enthrall.c,v 1.3 2006/08/18 17:17:01 tilman Exp $ + * $Id: enthrall.c,v 1.4 2006/08/18 17:22:47 tilman Exp $ * * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de) * @@ -117,6 +117,8 @@ "Options:\n" " -f, --fps=FPS " "frames per second (1-50, default: 25)\n" + " -p, --pointer=FILE " + "path to pointer image file\n" " -q, --quality=QUALITY " "JPEG quality (0-100, default: 90)\n" " -w, --window=WINDOW " @@ -152,10 +154,12 @@ main (int argc, char **argv) { Enthrall e; + char pointer_img[PATH_MAX]; double start; struct option options[] = { {"help", no_argument, NULL, 'h'}, {"fps", required_argument, NULL, 'f'}, + {"pointer", required_argument, NULL, 'p'}, {"quality", required_argument, NULL, 'q'}, {"window", required_argument, NULL, 'w'}, {NULL, no_argument, NULL, 0}}; @@ -176,6 +180,10 @@ case 'f': e.fps = atoi (optarg); break; + case 'p': + snprintf (pointer_img, sizeof (pointer_img), "%s", + optarg); + break; case 'q': e.quality = atoi (optarg); break; @@ -211,8 +219,8 @@ e.disp = ecore_x_display_get (); - if (file_exists ("pointer.png")) { - e.cursor.id = imlib_load_image ("pointer.png"); + if (file_exists (pointer_img)) { + e.cursor.id = imlib_load_image (pointer_img); imlib_context_set_image (e.cursor.id); e.cursor.w = imlib_image_get_width (); e.cursor.h = imlib_image_get_height (); ------------------------------------------------------------------------- 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