Commit ba9261ea authored by estade's avatar estade Committed by Commit bot
Browse files

Don't attempt to show validation bubble for unparented web contents.

This fix is speculative because I can't actually repro the bug.


Cr-Commit-Position: refs/heads/master@{#402349}
parent 0c915f7f
......@@ -1261,6 +1261,10 @@ void Browser::ShowValidationMessage(content::WebContents* web_contents,
const gfx::Rect& anchor_in_root_view,
const base::string16& main_text,
const base::string16& sub_text) {
// If the web contents is unparented (e.g. in a blocked popup) it does not
// make sense to show a validation message. See
if (!web_contents->GetTopLevelNativeWindow())
validation_message_bubble_ =
->ShowValidationMessage(anchor_in_root_view, main_text, sub_text);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment