On Sun, 16 Jan 2011 16:18:10 +0100 (CET) mathieu.taillefum...@free.fr said:

> Hello,
> 
> I wrote three additional functions allowing us yo change the backlight
> properties of the screes supporting it. I discover that the functions are
> already declared in the headers files but the code was not added so far. The
> patch is simple and should be directly applied in the directory
> src/lib/ecore_x/xlib after reviewing it. I am open for comments and
> suggestions for improving these three functions. 

ok ecore 1.0 is out. this can now go into ecore 1.1 dev (trunk). 
first.. patch is broken. - just some errors:

ecore_x_randr_12.c: In function ‘ecore_x_randr_screen_backlight_level_set’:
ecore_x_randr_12.c:1919: error: ‘_backlight’ undeclared (first use in this
function) ecore_x_randr_12.c:1919: error: (Each undeclared identifier is
reported only once ecore_x_randr_12.c:1919: error: for each function it appears
in.) ecore_x_randr_12.c: In function ‘ecore_x_randr_output_backlight_level_get’:
ecore_x_randr_12.c:1967: error: ‘_backlight’ undeclared (first use in this
function) ecore_x_randr_12.c: In function
‘ecore_x_randr_output_backlight_level_set’: ecore_x_randr_12.c:2012: warning:
‘return’ with no value, in function returning non-void ecore_x_randr_12.c:2014:
error: ‘_backlight’ undeclared (first use in this function) make: ***
[ecore_x_randr_12.lo] Error 1

where do you get _backlight from?

> I should indicate that I plan to create a module for e17 which controls the
> backlight properties but in order to do that I would like to ask a question.

that's cool! and you'd need the ecore support for it to work - fine.

> I would like to add a timer in this module in order decrease the backlight to
> a lower value after 10 seconds of activity for instance. For course the timer
> should be deactivited when the keyboard or the mouse are used but
> unfortunately I do not know how to create such timer. 

ecore_timer_add() - grep fore that call all through any code. easy to find
examples. but you need to know when inactivity has happened. for that you'd
need to look at the xscreensaver extension - you can get idle timeout events.
you could also poll every few seconds and get current idle time with
ecore_x_screensaver_idle_time_get(); (returns idle time in seconds)


-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    ras...@rasterman.com


------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to