Skip to content

Instantly share code, notes, and snippets.

@zed
Created November 9, 2013 21:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zed/7390230 to your computer and use it in GitHub Desktop.
Save zed/7390230 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
"""Demo for [gobject.timeout_add_seconds fails after system hibernation][1]
[1]: http://stackoverflow.com/q/19882390/
"""
import time
import gtk, glib
def callback():
print(time.asctime())
return True # continue
glib.timeout_add_seconds(1, callback)
gtk.main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment