View Single Post
Old 08-25-2010, 07:04 PM   #35
Iņigo
Guru
Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.
 
Posts: 730
Karma: 72743
Join Date: Feb 2008
Location: Here or there
Device: iRex iLiad, iRex DR800S. K4NT. Kobo Aura, Aura One, Libra 2.
Quote:
Originally Posted by CoolDragon View Post
I know nothing about GTK programming. The only thing that is similar to what we need seems to be the battery gauge: it will update when certain threshold is reached. Maybe there is similar trick that can be applied to the clock?

Another thought is: given the fact it actually updates when the menu bar is pressed, it is actually capable of doing a local refresh, but just ignoring some events. Is it possible to register some other events to the clock widget?
AFAIK it's not a gtk issue.
Battery uses images selecting among different icons (5?) depending on the battery level. I studied the code but it doesn't do anything special, change the image and do a gtk_widget_show() only.
I think that the image shown in screen remains static until a new full refresh is performed, showing the new image. That makes sense because battery doesn't drop from 50% to 25% in a small time frame, so any event will happen eventually.

I also thought in forcing an event like menu show/hide but didn't found anything easy to launch. We would need some esoteric arguments, such as context and some others...
Iņigo is offline   Reply With Quote