On Thu, 8 Mar 2007, Ravenlock wrote:

> On 03/08/2007 00:16, Vincent Torri wrote:
>> Hey,
>> 
>> I have a few questions about ecore_x_dpms.c
>> 
>> 1) As an X extension, why don't we query the extension, to see if it's 
>> available or not ?
>
> Thats what ecore_x_dpms_capable is responsible for.  And it is used when 
> initializing the config panel dialog to see if the extension is available 
> (see _e_int_config_dpms_capable() in e_int_config_dpms.c). Have I 
> misunderstood your question?

I think so. See DPMSQueryExtension. Briefly, that function tells you if 
the extension is available or not in your X server. DPMSCapable tells you 
if the running server's devices are capable of DPMS operations or not.

>> 2) I would like to rename ecore_x_dpms_capable to ecore_x_dpms_capable_get 
>> and *_timeout_* to *_timeouts_*. No objection for that ?
>> 
>
> *_capable() -> *_capable_get() is a "don't care" for me.

ok. The I prefer _get than nothing.

> The functions that get/set an individual timeout are named *_timeout_*.  The 
> one that allows you to set all at once is named *_timeouts_*.  Is this not 
> already what you are suggesting?

ok for letting the name as they are now.

>> 3) is it really necessary to have 3 functions to get the timeouts, instead 
>> of one that returns all the info ?
>
> Is it *necessary*?  No.  Does it provide some convenience for a developer? 
> Maybe?  Are they even used?  I forget.  Why did I put them there in the first 
> place?  Out of habit.  I have a habit (good or bad?) of exposing properties 
> of "objects", if you want to view DPMS as such, individually.  Mostly a 
> "don't care" for me here to.

If you want 2 or 3 of these values, you'll have 2 or 3 round trips, 
instead of 1. So I would vote for adding one function that returns the 3 
values.

Vincent

-------------------------------------------------------------------------
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-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to