Adding timeout at searching window for switching

After opening new window it may be available
for switching by handle but not yet by window name.
Error "Unable to get document, IWebBrowser2::get_Document call failed"
is whon in such case.
For preventing such problem timeout (10 times for 100ms)
is added during searching window by handle/name.

Fixes issue #2764.