diff options
author | Assim Deodia <assim.deodia@gmail.com> | 2008-07-03 16:50:55 (GMT) |
---|---|---|
committer | Assim Deodia <assim.deodia@gmail.com> | 2008-07-03 16:50:55 (GMT) |
commit | 2b70f37fbd9eba4413dbb80351104aa9b6f3ea66 (patch) | |
tree | dc6ffc8db34296160db6c13c97acb8e5c8abfd65 /las.py | |
parent | 374c6b082614bfdb26ce6241ab1d7e18dad5acb3 (diff) |
LaS init function modified
Diffstat (limited to 'las.py')
-rw-r--r-- | las.py | 7 |
1 files changed, 2 insertions, 5 deletions
@@ -44,7 +44,7 @@ class _GetchWindows: class Listenspell(): - def __init__(self): + def __init__(self, SQLiteDB): self.skill_level = 0 self.level_threshold = 5 @@ -52,12 +52,11 @@ class Listenspell(): self.words_played = 0 self.words_correct = 0 self.init = False - self.dict_obj = Dict() + self.dict_obj = Dict(SQLiteDB) #Always intitiate first Dict object then Word object self.word_obj = Word() def start_speechd(self): # Currently not in use have to manually start sugar-speechd - import os pid = os.fork() if pid: return @@ -122,7 +121,6 @@ class Listenspell(): def get_word_info(self,wordid, attribute): if self.word_obj.get_wordid() != wordid: self.word_obj.__init__(identifier = "wordid", value= wordid) - print "Hello Again" self.words_played = self.words_played + 1 if attribute == "def": @@ -147,7 +145,6 @@ class Listenspell(): def get_key(self): for longestinput in range(15): inkey = _Getch() - import sys for i in xrange(sys.maxint): k=inkey() if k<>'':break |