This commit is contained in:
HuangHai
2026-01-26 09:25:18 +08:00
parent d9bb1d1f83
commit 5a11e691a4
11 changed files with 30 additions and 111 deletions

View File

@@ -315,7 +315,9 @@ async def analyze_chat_image(image_path, output_path, device=None, target_name="
if should_trigger_convert:
# 转换完成后稍微多等一下,确保 UI 刷新
time.sleep(1.0)
return "VOICE_CONVERTING", input_field_coordinates
# 即使触发了转换,我们也返回当前的对话日志,但在日志末尾注明正在转换
dialogue_log.append("系统: [正在转换语音...]")
return dialogue_log, input_field_coordinates
return dialogue_log, input_field_coordinates
@@ -568,9 +570,12 @@ def perform_input_action(d, center_point, text, auto_send=True):
os.remove(tmp_screen)
except:
pass
return True
except Exception as e:
logger.error(f"perform_input_action error: {e}")
return False
def match_template_center(image_path, template_path, threshold=0.8):
"""