On Wed, 13 Dec 2006, Johan Bilien wrote:

> On Wed, Dec 13, 2006, Aaron Levinson wrote:
> > In the Maemo coding style and programming guidelines document on
> > maemo.org, it states the following:  "Avoid updating the GUI when the
> > application running on the background and when the screen has been turned
> > off. Remove unnecessary graphical elements or constantly updated screen
> > components."  Now, it appears that hildon_window_get_is_topmost() or
> > hildon_program_get_is_topmost() can be used to determine if an application
> > is running in the background, but how does one programmatically determine
> > if the screen has been turned off?  I see in the latest version of libosso
> > in SVN that there is a muali API that provides the ability to access the
> > information via a callback, but it is unclear how to determine this on 2.0
> > or 2.1.  Perhaps I can use XScreenSaverQueryInfo() ?
> 
> http://maemo.org/platform/docs/api/libosso/html/index.html
> 
> You can register a callback with osso_hw_set_event_cb, set the
> system_inactivity_ind flag in the osso_hw_state_t argument.

Well, I had already examining the libosso APIs before sending the e-mail,
and I did notice the system_inactivity_ind flag in the osso_hw_state_t
struct.  However, according to the libosso documentation, if the callback
is called for system inactivity, this means that "the application should
reduce its activity".  I didn't directly associate this text with the
screen being blanked, which I think is understandable, since screen
blanking is not the same thing.

What are the conditions that result in the callback for the system 
inactivity indicator being called?  The statement "the application should 
reduce its activity" is somewhat open-ended, and perhaps this callback is 
used for more than just to indicate that the screen has been blanked.

Thanks,
Aaron

_______________________________________________
maemo-developers mailing list
maemo-developers@maemo.org
https://maemo.org/mailman/listinfo/maemo-developers

Reply via email to