a17cd4759c
To pace the output lines, implement a simple wait() call for the i3 output.
20 lines
409 B
Python
20 lines
409 B
Python
import json
|
|
import time
|
|
|
|
class i3(object):
|
|
def start(self):
|
|
return '{}\n'.format(json.dumps({ 'version': 1, 'click_events': True }))
|
|
|
|
def stop(self):
|
|
return ']\n'
|
|
|
|
def begin_status_line(self):
|
|
return '['
|
|
|
|
def end_status_line(self):
|
|
return '],\n'
|
|
|
|
def wait(self, interval):
|
|
time.sleep(interval)
|
|
|
|
# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4
|