MCPcopy Create free account
hub / github.com/Xu22Web/tech-study-js / waitTaskWin

Function waitTaskWin

tech-study.js:3713–3731  ·  view source on GitHub ↗

* @description 打开并等待任务结束

(url, title)

Source from the content-addressed store, hash-verified

3711 * @description 打开并等待任务结束
3712 */
3713async function waitTaskWin(url, title) {
3714 // 同屏任务
3715 if (settings[SettingType.SAME_TAB]) {
3716 // 窗口存在
3717 frame.exist = true;
3718 // 显示窗体
3719 frame.show = !settings[SettingType.SILENT_RUN];
3720 // 新窗口
3721 const res = await openFrame(url, title);
3722 if (res) {
3723 // 等待窗口关闭
3724 await waitFrameClose();
3725 }
3726 return;
3727 }
3728 // 子页面任务
3729 page.value = openWin(url);
3730 await waitWinClose(page.value);
3731}
3732/**
3733 * @description 二维码刷新定时器
3734 */

Callers 4

doExamPracticeFunction · 0.70
doExamPaperFunction · 0.70
readNewsFunction · 0.70
watchVideoFunction · 0.70

Calls 4

openFrameFunction · 0.70
waitFrameCloseFunction · 0.70
openWinFunction · 0.70
waitWinCloseFunction · 0.70

Tested by

no test coverage detected