Closed magreenblatt closed 13 years ago
Original comment by Dmitry Azaraev (Bitbucket: Mystic Artifact).
Comment 1. originally posted by fddima on 2011-09-15T20:34:34.000Z:
I confirm this issue.
In CefGlue i'm use workaround for this - i'm post task to UI thread to execute SetFocus.
Comment 2. originally posted by magreenblatt on 2011-10-21T20:50:20.000Z:
Thanks, fixed in revision 335.
Original report by Anonymous.
Original issue 320 created by ckchien on 2011-08-31T11:33:45.000Z:
What steps will reproduce the problem?
What is the expected output? What do you see instead?
Should not get exception in SetFocus().
What version of the product are you using? On what operating system?
Windows 7
Please provide any additional information below.
Trace to browser_impl.cc:
void CefBrowserImpl::SetFocus(bool enable)
{
if (CefThread::CurrentlyOn(CefThread::UI)) {
UIT_SetFocus(UIT_GetWebViewHost(), enable);
} else {
CefThread::PostTask(CefThread::UI, FROM_HERE, NewRunnableMethod(this,
&CefBrowserImpl::UIT_SetFocus, UIT_GetWebViewHost(), enable));
}
}
Original SetFocus() seems to support called from non UI thread.
But it calls UIT_GetWebViewHost().
In UIT_GetWebViewHost(), there is a REQUIRE_UIT() assertion and lead to exception.
Could you please check if my understanding is right?
Thanks in advanced.