From e68b9da9c71fe429ad796d2e4218204b615e9dfc Mon Sep 17 00:00:00 2001 From: CHUN YU YAO Date: Tue, 26 Mar 2024 00:10:00 +0800 Subject: [PATCH] show message for kktix. --- chrome_tixcraft.py | 8 +++++++- settings.py | 8 ++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/chrome_tixcraft.py b/chrome_tixcraft.py index 0656ca8..6fc355e 100644 --- a/chrome_tixcraft.py +++ b/chrome_tixcraft.py @@ -7968,7 +7968,13 @@ def kktix_main(driver, url, config_dict, kktix_dict): if config_dict["advanced"]["play_sound"]["order"]: if not kktix_dict["played_sound_order"]: play_sound_while_ordering(config_dict) - kktix_dict["played_sound_order"] = True + + if not kktix_dict["played_sound_order"]: + if len(config_dict["advanced"]["kktix_account"]) > 0: + print("搶票成功, 帳號:", config_dict["advanced"]["kktix_account"]) + print("基本資料與實名制網址:", url) + + kktix_dict["played_sound_order"] = True if config_dict["advanced"]["headless"]: diff --git a/settings.py b/settings.py index dba9b59..75dcc42 100644 --- a/settings.py +++ b/settings.py @@ -757,7 +757,7 @@ def get_default_config(): config_dict["advanced"]["auto_reload_page_interval"] = 0.1 config_dict["advanced"]["reset_browser_interval"] = 0 config_dict["advanced"]["proxy_server_port"] = "" - config_dict["advanced"]["window_size"] = "512,520" + config_dict["advanced"]["window_size"] = "512,580" config_dict["advanced"]["idle_keyword"] = "" config_dict["advanced"]["resume_keyword"] = "" @@ -1341,7 +1341,7 @@ def play_mp3(sound_filename): playsound(sound_filename) except Exception as exc: msg=str(exc) - print("play sound exeption:", msg) + #print("play sound exeption:", msg) if platform.system() == 'Windows': import winsound try: @@ -2740,10 +2740,6 @@ def check_maxbot_config_unsaved(config_dict): global txt_idle_keyword_second global txt_resume_keyword_second - style = ttk.Style() - style.configure("redStyle.TCombobox", foreground="red") - style.configure("greenStyle.TCombobox", foreground="green") - try: date_keyword = "" if 'txt_date_keyword' in globals():