Files
douyin_guaji-main/gui
CodexandClaude Opus 4.7 a71f6faed0 feat(wifi_adb): 记住上次成功的 WiFi 设备,GUI 启动时自动重连
新增 gui/gui_core_pkg/config.py 三个 helper:
- get_last_wifi_target  / set_last_wifi_target / clear_last_wifi_target
配置以 last_wifi_target = {target, model, saved_at} 形式存在 config.json 顶层。

GUI 行为:
- "扫描 WiFi" 选中或自动连上一台 connected 设备 → 写入 last_wifi_target
- WiFi 选择对话框"使用选中"也写入
- 主窗口启动后延迟 300ms 后台尝试 verify_adb_target(last.target)
  - 已有设备:不打扰
  - 重连成功:自动设为当前设备
  - unauthorized:提示需手机端授权
  - 不可达:提示换网了,引导点'扫描 WiFi'

新增 12 个 last_wifi_target 单元测试覆盖读写/清除/损坏值/缺文件等场景。

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 20:16:37 +08:00
..

GUI 目录

本目录包含项目的所有图形用户界面相关文件。

文件列表

  • gui_app.py - 主GUI应用程序(基于tkinter/ttkbootstrap)
  • gui_core.py - GUI核心功能模块(参数处理、设备管理、配置读写等)
  • web_gui.py - Web GUI服务器
  • webgui_launcher.py - Web GUI启动器

使用方法

桌面GUI

python gui/gui_app.py

Web GUI

python gui/webgui_launcher.py