Move AutofillPopup from NativeWindow to WebContents (#12514)

This commit is contained in:
Cheng Zhao 2018-04-05 09:53:51 +09:00 committed by GitHub
parent 3a45d541f3
commit c75dd93b92
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 123 additions and 126 deletions

View file

@ -189,6 +189,9 @@ void CommonWebContentsDelegate::SetOwnerWindow(
auto relay = base::MakeUnique<NativeWindowRelay>(owner_window_);
auto relay_key = relay->key;
if (owner_window) {
#if defined(TOOLKIT_VIEWS)
autofill_popup_.reset(new AutofillPopup());
#endif
web_contents->SetUserData(relay_key, std::move(relay));
} else {
web_contents->RemoveUserData(relay_key);