fix things

This commit is contained in:
root
2016-07-12 16:51:26 +02:00
parent d17135da01
commit f67176771a
3 changed files with 20 additions and 14 deletions

View File

@ -54,7 +54,7 @@ class screenManager():
(len(environment['screenData']['newContentText']) > 0):
diff = difflib.ndiff(" ".join(environment['screenData']['oldContentText'].split()), " ".join(environment['screenData']['newContentText'].split()))
environment['screenData']['delta'] = ''.join(x[2:] for x in diff if x.startswith('+ '))
if ((len(environment['screenData']['delta']) < 3)):
if ((len(environment['screenData']['delta']) == 1)):
environment['runtime']['speechDriver'].cancel()
environment['runtime']['speechDriver'].speak(environment['screenData']['delta'])
# set new "old" values