HandleKeyboardEvent returns bool

1262404
This commit is contained in:
Jeremy Apthorp 2019-01-09 12:01:49 -08:00
parent fd7b49b32b
commit 30e5e993c1
7 changed files with 26 additions and 17 deletions

View file

@ -617,15 +617,15 @@ void WebContents::UpdateTargetURL(content::WebContents* source,
Emit("update-target-url", url);
}
void WebContents::HandleKeyboardEvent(
bool WebContents::HandleKeyboardEvent(
content::WebContents* source,
const content::NativeWebKeyboardEvent& event) {
if (type_ == WEB_VIEW && embedder_) {
// Send the unhandled keyboard events back to the embedder.
embedder_->HandleKeyboardEvent(source, event);
return embedder_->HandleKeyboardEvent(source, event);
} else {
// Go to the default keyboard handling.
CommonWebContentsDelegate::HandleKeyboardEvent(source, event);
return CommonWebContentsDelegate::HandleKeyboardEvent(source, event);
}
}