Patch for HUD and FTP tourneys

modified:   Hand.py
	- writeTableLine : adds the tourneyNo in tourney context
	modified:   Tables.py
	- discover_nt_by_name : add filter for HUD and chat windows
This commit is contained in:
PassThePeas 2009-09-12 23:14:55 +02:00
parent 49ce7de254
commit 16d53f1502
2 changed files with 9 additions and 1 deletions

View File

@ -596,7 +596,11 @@ Map the tuple self.gametype onto the pokerstars string describing it
def writeTableLine(self): def writeTableLine(self):
table_string = "Table \'%s\' %s-max" % (self.tablename, self.maxseats) table_string = "Table "
if self.gametype['type'] == 'tour':
table_string = table_string + "\'%s %s\' %s-max" % (self.tourNo, self.tablename, self.maxseats)
else:
table_string = table_string + "\'%s\' %s-max" % (self.tablename, self.maxseats)
if self.gametype['currency'] == 'play': if self.gametype['currency'] == 'play':
table_string = table_string + " (Play Money)" table_string = table_string + " (Play Money)"
if self.buttonpos != None and self.buttonpos != 0: if self.buttonpos != None and self.buttonpos != 0:

View File

@ -253,6 +253,10 @@ def discover_nt_tournament(c, tour_number, tab_number):
titles ={} titles ={}
win32gui.EnumWindows(win_enum_handler, titles) win32gui.EnumWindows(win_enum_handler, titles)
for hwnd in titles: for hwnd in titles:
if 'Chat:' in titles[hwnd]: continue # Some sites (FTP? PS? Others?) have seperable or seperately constructed chat windows
if 'History for table:' in titles[hwnd]: continue # Everleaf Network HH viewer window
if 'HUD:' in titles[hwnd]: continue # FPDB HUD window
if re.search(search_string, titles[hwnd]): if re.search(search_string, titles[hwnd]):
return decode_windows(c, titles[hwnd], hwnd) return decode_windows(c, titles[hwnd], hwnd)
return None return None