Check that the return value of CefClient::GetRenderHandler is non-NULL (issue #1504).

git-svn-id: https://chromiumembedded.googlecode.com/svn/branches/2272@1996 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2015-01-26 00:57:43 +00:00
parent dc47bc006a
commit 5e13ce6df7
6 changed files with 73 additions and 45 deletions

View File

@ -1105,10 +1105,11 @@ void CefBrowserHostImpl::PlatformTranslateMouseEvent(
result.globalY = result.y;
if (IsWindowless()) {
GetClient()->GetRenderHandler()->GetScreenPoint(
GetBrowser(),
result.x, result.y,
result.globalX, result.globalY);
CefRefPtr<CefRenderHandler> handler = client_->GetRenderHandler();
if (handler.get()) {
handler->GetScreenPoint(this, result.x, result.y, result.globalX,
result.globalY);
}
} else {
POINT globalPoint = { result.x, result.y };
ClientToScreen(GetWindowHandle(), &globalPoint);