From c6d404834ec8353ca16b053d2801f069d49ba2a6 Mon Sep 17 00:00:00 2001 From: Your Name Date: Sat, 3 Jan 2026 20:33:23 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E6=9B=B4=E6=96=B0=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E6=88=B3=EF=BC=8C=E4=BC=98=E5=8C=96=E7=95=8C=E9=9D=A2?= =?UTF-8?q?=E5=85=83=E7=B4=A0=E7=9A=84=E5=B8=83=E5=B1=80=E5=92=8C=E6=A0=BC?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- douyin/core/state/reservations.json | 2 +- gui/gui_app.py | 36 +++++++++++++++++------------ 2 files changed, 22 insertions(+), 16 deletions(-) diff --git a/douyin/core/state/reservations.json b/douyin/core/state/reservations.json index a163ed9..fd6518f 100644 --- a/douyin/core/state/reservations.json +++ b/douyin/core/state/reservations.json @@ -1,5 +1,5 @@ { - "updated_ts": 1767440958.0048747, + "updated_ts": 1767442907.6341074, "reason": "startup_clear", "room_pos": 0, "current_room_title": "", diff --git a/gui/gui_app.py b/gui/gui_app.py index 020065a..e1775b0 100644 --- a/gui/gui_app.py +++ b/gui/gui_app.py @@ -2213,21 +2213,24 @@ def main(): realtime_tools = ttk.Frame(right) realtime_tools.pack(fill=X, padx=8, pady=(4, 0)) - ttk.Checkbutton( - realtime_tools, text="显示动作流", variable=show_actions_var - ).pack(side=LEFT, padx=(0, 8)) - ttk.Checkbutton( - realtime_tools, text="显示截图", variable=show_screenshot_var - ).pack(side=LEFT, padx=(0, 8)) - ttk.Checkbutton( - realtime_tools, text="自动滚动", variable=auto_scroll_var - ).pack(side=LEFT, padx=(0, 8)) + ttk.Checkbutton(realtime_tools, text="显示动作流", variable=show_actions_var).pack( + side=LEFT, padx=(0, 8) + ) + ttk.Checkbutton(realtime_tools, text="显示截图", variable=show_screenshot_var).pack( + side=LEFT, padx=(0, 8) + ) + ttk.Checkbutton(realtime_tools, text="自动滚动", variable=auto_scroll_var).pack( + side=LEFT, padx=(0, 8) + ) # forward-declare handler to satisfy linters; real function defined later open_realtime_viewer = lambda: None - ttk.Button(realtime_tools, text="实时查看", width=10, command=lambda: open_realtime_viewer()).pack( - side=LEFT, padx=(8, 0) - ) + ttk.Button( + realtime_tools, + text="实时查看", + width=10, + command=lambda: open_realtime_viewer(), + ).pack(side=LEFT, padx=(8, 0)) log_tab = ttk.Frame(notebook) preview_tab = ttk.Frame(notebook) @@ -2257,8 +2260,6 @@ def main(): realtime_frame = ttk.Frame(realtime_tab) realtime_frame.pack(fill=BOTH, expand=True, padx=8, pady=8) - - # 截图预览区域(根据选项显示/隐藏) image_label = ttk.Label(realtime_frame) image_label.pack(fill=X) @@ -2439,7 +2440,9 @@ def main(): list_frame.pack(fill=BOTH, expand=True, padx=6, pady=6) listbox = tk.Listbox(list_frame, height=12) listbox.pack(side=LEFT, fill=BOTH, expand=True) - scrollbar = ttk.Scrollbar(list_frame, orient=tk.VERTICAL, command=listbox.yview) + scrollbar = ttk.Scrollbar( + list_frame, orient=tk.VERTICAL, command=listbox.yview + ) scrollbar.pack(side=RIGHT, fill=Y) listbox.configure(yscrollcommand=scrollbar.set) @@ -4636,6 +4639,9 @@ def main(): on_line(f"[中奖记录] 打开目录失败:{e}") ttk.Button(win_record_top, text="打开目录", command=open_win_folder).pack(side=LEFT) + ttk.Button( + win_record_top, text="实时查看", command=lambda: open_realtime_viewer() + ).pack(side=LEFT, padx=(8, 0)) # 误识别记录管理 false_positive_frame = ttk.LabelFrame(win_record_right, text="误识别记录管理")