MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / FindEdgeChildWindowForProcess

Method FindEdgeChildWindowForProcess

cpp/iedriver/BrowserFactory.cpp:1210–1235  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1208}
1209
1210BOOL CALLBACK BrowserFactory::FindEdgeChildWindowForProcess(HWND hwnd, LPARAM arg) {
1211 ProcessWindowInfo* process_window_info = reinterpret_cast<ProcessWindowInfo*>(arg);
1212
1213 // Could this be an Internet Explorer Server window?
1214 // 25 == "Internet Explorer_Server\0"
1215 char name[25];
1216 if (::GetClassNameA(hwnd, name, 25) == 0) {
1217 // No match found. Skip
1218 return TRUE;
1219 }
1220
1221 if (strcmp(IE_SERVER_CHILD_WINDOW_CLASS, name) != 0) {
1222 return TRUE;
1223 }
1224 else {
1225 DWORD process_id = NULL;
1226 ::GetWindowThreadProcessId(hwnd, &process_id);
1227 LOG(DEBUG) << "Looking for " << process_window_info->dwProcessId;
1228 // Once we've found the first Internet Explorer_Server window
1229 // for the process we want, we can stop.
1230 process_window_info->hwndBrowser = hwnd;
1231 return FALSE;
1232 }
1233
1234 return TRUE;
1235}
1236
1237BOOL CALLBACK BrowserFactory::FindDialogWindowForProcess(HWND hwnd, LPARAM arg) {
1238 ProcessWindowInfo* process_win_info = reinterpret_cast<ProcessWindowInfo*>(arg);

Callers

nothing calls this directly

Calls 1

LOGClass · 0.50

Tested by

no test coverage detected