Really, my backend is a console player, so, with commands, I can get the state, for example: mocp -Q %state gets the pause/stop/playing state of the "backend".
I can't send signal to my python program because I amn't the developer of the console player, I go to try the timeout_add. Thanks to all! 2009/6/6 Kelvin Ho <kelvin.ho.ka....@gmail.com> > Hi, > > If your GUI needs to do some task periodically, you can use > gobject.timeout_add to attach a callback. Here's the reference: > > http://pygtk.org/docs/pygobject/gobject-functions.html#function-gobject--timeout-add > > Hope that helps. > > Kelvin > > 2009/6/6 Alexandre González <a...@rianxosencabos.com> > >> Hi! >> >> >> I like to know the best way to refresh my buttons... I go to explain. I'm >> developing a frontend, so I depend that the backend change some values, so >> after a little time I need to read some propertys from the backend and setup >> my frontend button. What's the best way to do it and don't use a lot of CPU. >> >> Thank you! >> >> -- >> Please, don't send me files with extensions: .doc, .docx, .xls, .xlsx, >> .ppt and/or .pptx >> http://mirblu.com >> >> _______________________________________________ >> pygtk mailing list pygtk@daa.com.au >> http://www.daa.com.au/mailman/listinfo/pygtk >> Read the PyGTK FAQ: http://faq.pygtk.org/ >> > > -- Please, don't send me files with extensions: .doc, .docx, .xls, .xlsx, .ppt and/or .pptx http://mirblu.com
_______________________________________________ pygtk mailing list pygtk@daa.com.au http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://faq.pygtk.org/