self.pipeline.set_state(Gst.State.NULL)
self.loop.quit()
- def switch(self):
+ def on_switch(self):
self.uri_index ^= 1
print("Next: %s" % self.uris[self.uri_index])
def stdin_cb(source, condition):
source.readline()
- player.switch()
+ player.on_switch()
return True
GObject.io_add_watch(sys.stdin, GObject.IO_IN, stdin_cb)