Enlightenment CVS committal

Author  : rephorm
Project : e17
Module  : apps/elicit

Dir     : e17/apps/elicit/src


Modified Files:
        Elicit.h Makefile.am callbacks.c elicit.c themes.c util.c 
Added Files:
        spectrum.c spectrum.h 


Log Message:
sliders and spectra!


===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/Elicit.h,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- Elicit.h    11 Jul 2006 05:23:00 -0000      1.17
+++ Elicit.h    15 Jul 2006 06:47:01 -0000      1.18
@@ -37,6 +37,7 @@
 #include "swatches.h"
 #include "shots.h"
 #include "themes.h"
+#include "spectrum.h"
 #include "zoom.h"
 
 
===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/Makefile.am,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -3 -r1.8 -r1.9
--- Makefile.am 11 Jul 2006 05:23:00 -0000      1.8
+++ Makefile.am 15 Jul 2006 06:47:01 -0000      1.9
@@ -13,6 +13,7 @@
         swatches.c swatches.h \
         shots.c shots.h \
         themes.c themes.h \
+                               spectrum.c spectrum.h \
                                zoom.c zoom.h
 
 elicit_LDADD = @edje_libs@ @ecore_libs@ @edb_libs@ @evas_libs@ \
===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/callbacks.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -3 -r1.21 -r1.22
--- callbacks.c 11 Jul 2006 05:23:00 -0000      1.21
+++ callbacks.c 15 Jul 2006 06:47:01 -0000      1.22
@@ -39,15 +39,10 @@
   ecore_evas_geometry_get(ee, NULL, NULL, &w, &h);
 
   gui = evas_object_name_find(ecore_evas_get(ee), "gui");
-  shot = evas_object_name_find(ecore_evas_get(ee), "shot");
   draggie = evas_object_name_find(ecore_evas_get(ee), "draggie");
 
   evas_object_resize(gui, w, h);
   evas_object_resize(draggie, w, h);
-
-  /* keep the shot filling its bounds */
-  evas_object_geometry_get(shot, NULL, NULL, &sw, &sh);
-  evas_object_image_fill_set(shot, 0, 0, sw, sh);
 }
 
 void elicit_cb_pick(void *data, Evas_Object *o, const char *sig, const char 
*src)
===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/elicit.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -3 -r1.27 -r1.28
--- elicit.c    11 Jul 2006 05:23:00 -0000      1.27
+++ elicit.c    15 Jul 2006 06:47:01 -0000      1.28
@@ -146,6 +146,7 @@
   elicit_swatches_init(el);
   elicit_shots_init(el);
   elicit_themes_init(el);
+  elicit_spectra_init(el);
 
   elicit_ui_update(el);
   return 0;
@@ -295,6 +296,7 @@
   elicit_ui_update_text(el);
   elicit_ui_update_sliders(el);
   elicit_zoom_zoom_set(el->shot, el->zoom);
+  elicit_spectra_update(el);
   
   evas_object_color_set(el->swatch, el->color.r, el->color.g, el->color.b, 
255);
 }
===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/themes.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -3 -r1.7 -r1.8
--- themes.c    5 Sep 2005 19:45:47 -0000       1.7
+++ themes.c    15 Jul 2006 06:47:01 -0000      1.8
@@ -94,10 +94,10 @@
   esmart_container_element_remove(el->themes.cont, o);
   evas_object_del(o);
 
-#if 1
   elicit_shots_shutdown(el);
   elicit_swatches_shutdown(el);
   elicit_themes_shutdown(el);
+  elicit_spectra_shutdown(el);
 
   evas_object_del(el->gui);
   
@@ -111,7 +111,7 @@
   elicit_shots_init(el);
   elicit_swatches_init(el);
   elicit_themes_init(el);
-#endif
+  elicit_spectra_init(el);
 }
 
 
===================================================================
RCS file: /cvs/e/e17/apps/elicit/src/util.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- util.c      11 Jul 2006 05:23:00 -0000      1.12
+++ util.c      15 Jul 2006 06:47:01 -0000      1.13
@@ -16,11 +16,9 @@
   Imlib_Image *im;
   Imlib_Color col;
   int x, y;
-  int tr;
-  Window dummy;
 
   /* where are we pointing? */
-  XQueryPointer(ecore_x_display_get(), RootWindow(ecore_x_display_get(),0), 
&dummy, &dummy, &tr, &tr, &x, &y, &tr);
+  ecore_x_pointer_last_xy_get(&x, &y);
 
   /* setup the imlib context */
   imlib_context_set_display(ecore_x_display_get());
@@ -32,71 +30,12 @@
   imlib_context_set_image(im);
   imlib_image_query_pixel(0, 0, &col);
 
-  //evas_object_color_set(swatch.obj, col.red, col.green, col.blue, 255);
   /* set the color values */
   if (r) *r = col.red;
   if (g) *g = col.green;
   if (b) *b = col.blue;
 
-  /* update the other formats */
-  /*
-  _rgb_to_hsv();
-  _rgb_to_hex();
-
-  elicit_ui_update_text(el);
-  changed = 1;
-  */
   imlib_free_image(); 
-
-}
-
-void
-elicit_util_shoot(Evas_Object *shot, int w, int h)
-{
-  Imlib_Image *im;
-  int x, y;
-  int px, py;
-  int dw, dh;
-  int tr;
-  Evas_Coord sw, sh;
-  Window dummy;
-
-  XQueryPointer(ecore_x_display_get(), RootWindow(ecore_x_display_get(),0), 
&dummy, &dummy, &tr, &tr, &px, &py, &tr);
-
-  x = px - .5 * w;
-  y = py - .5 * h;
-
-  ecore_x_window_size_get(RootWindow(ecore_x_display_get(),0), &dw, &dh);
-  if (x < 0) x = 0;
-  if (y < 0) y = 0;
-  if (x + w > dw) x = dw - w;
-  if (y + h > dh) y = dh - h;
-
-  /* setup the imlib context */
-  imlib_context_set_display(ecore_x_display_get());
-  imlib_context_set_drawable(RootWindow(ecore_x_display_get(),0));
-  imlib_context_set_visual( DefaultVisual(ecore_x_display_get(), 
DefaultScreen(ecore_x_display_get() ) ));
-
-  /* copy the correct part of the screen */
-  im = imlib_create_image_from_drawable(0, x, y, w, h, 1);
-  imlib_context_set_image(im);
-  imlib_image_set_format("argb");
-
-  /* get the object ready, copy the data in */
-  evas_object_image_alpha_set(shot, 0);
-  evas_object_image_size_set(shot, w, h);
-  evas_object_image_smooth_scale_set(shot, 0);
-
-  evas_object_image_data_copy_set(shot, 
imlib_image_get_data_for_reading_only());
-  
-  /* tell evas that we changed part of the image data */
-  evas_object_image_data_update_add(shot, 0, 0, w, h);
-
-  /* set it to fill the whole object */
-  evas_object_geometry_get(shot, NULL, NULL, &sw, &sh);
-  evas_object_image_fill_set(shot, 0, 0, sw, sh);
-
-  imlib_free_image();
 }
 
 void




-------------------------------------------------------------------------
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