update 检测登出后关闭功能

This commit is contained in:
gallonyin
2023-09-21 21:30:31 +08:00
parent e5a9ed679f
commit eabf9ecfa3
2 changed files with 3 additions and 1 deletions

View File

@@ -75,6 +75,8 @@ fun goHomeTab(title: String): Boolean {
if (AccessibilityUtil.findOnceByText(getRoot(), "手机号登录", exact = true) != null) {
LogUtils.e("登录前请先关闭WorkTool主功能")
ToastUtils.show("登录前请先关闭WorkTool主功能")
WeworkController.weworkService.disableSelf()
WeworkController.weworkService.webSocketManager.close(1000, "wework logout")
MyApplication.launchIntent()
sleep(5000)
}

View File

@@ -46,7 +46,7 @@ object WeworkLoopImpl {
}
if (!mainLoopRunning) break
if (getChatroomList()) {
LogUtils.d("进入点击进入聊天页: ")
LogUtils.d("点击进入聊天页: ")
AccessibilityUtil.waitForPageMissing("WwMainActivity", "GlobalSearchActivity")
if (!getChatMessageList()) {
sleep(Constant.POP_WINDOW_INTERVAL)