| 157 | } |
| 158 | |
| 159 | DWORD WINAPI MonitorThread(LPVOID lpParam) { |
| 160 | HANDLE hProcessSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); |
| 161 | PROCESSENTRY32 process = { sizeof(PROCESSENTRY32) }; |
| 162 | |
| 163 | // 遍历进程 |
| 164 | while (Process32Next(hProcessSnap, &process)) { |
| 165 | if (strstr(wstring2string(process.szExeFile).c_str(), "csrss.exe")) |
| 166 | processIdMap[process.th32ProcessID] = true; |
| 167 | } |
| 168 | |
| 169 | while (1) |
| 170 | EnumWindows(lpEnumFunc, (LPARAM)&processIdMap); |
| 171 | |
| 172 | return 0; |
| 173 | } |
| 174 | |
| 175 | bool isNeedWait = true; |
| 176 | void showWaiting() { |
nothing calls this directly
no test coverage detected