def main(): import glib import gtk def show(): n = DBUS_Notifier_factory() n.show_notify("", None, 0, "Test", 0, "", "Summary", "Body line1\nline2...", ["0", "Hello", "1", "Bye"], {}, 0, "") return False glib.idle_add(show) glib.timeout_add(20000, gtk.main_quit) gtk.main()
def main(): from xpra.gtk_common.gobject_compat import import_glib, import_gtk glib = import_glib() gtk = import_gtk() def show(): n = DBUS_Notifier_factory() n.show_notify("", None, 0, "Test", 0, "", "Summary", "Body line1\nline2...", ["0", "Hello", "1", "Bye"], {}, 0, "") return False glib.idle_add(show) glib.timeout_add(20000, gtk.main_quit) gtk.main()