Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(52)

Unified Diff: components/autofill/content/browser/content_autofill_driver.cc

Issue 2180093002: [Autofill] Switch on use_new_wrapper_types mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address nit Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/autofill/content/browser/content_autofill_driver.cc
diff --git a/components/autofill/content/browser/content_autofill_driver.cc b/components/autofill/content/browser/content_autofill_driver.cc
index c031fe4a6c27ffe6cd117112557cfd885370169d..3f4ce7928c9ad4461bef10694c7efe41504344e5 100644
--- a/components/autofill/content/browser/content_autofill_driver.cc
+++ b/components/autofill/content/browser/content_autofill_driver.cc
@@ -25,7 +25,6 @@
#include "content/public/browser/site_instance.h"
#include "content/public/browser/storage_partition.h"
#include "content/public/browser/web_contents.h"
-#include "mojo/common/common_type_converters.h"
#include "services/shell/public/cpp/interface_provider.h"
#include "ui/gfx/geometry/size_f.h"
@@ -116,15 +115,14 @@ void ContentAutofillDriver::SendAutofillTypePredictionsToRenderer(
std::vector<FormDataPredictions> type_predictions =
FormStructure::GetFieldTypePredictions(forms);
- GetAutofillAgent()->FieldTypePredictionsAvailable(
- std::move(type_predictions));
+ GetAutofillAgent()->FieldTypePredictionsAvailable(type_predictions);
}
void ContentAutofillDriver::RendererShouldAcceptDataListSuggestion(
const base::string16& value) {
if (!RendererIsAvailable())
return;
- GetAutofillAgent()->AcceptDataListSuggestion(mojo::String::From(value));
+ GetAutofillAgent()->AcceptDataListSuggestion(value);
}
void ContentAutofillDriver::RendererShouldClearFilledForm() {
@@ -143,14 +141,14 @@ void ContentAutofillDriver::RendererShouldFillFieldWithValue(
const base::string16& value) {
if (!RendererIsAvailable())
return;
- GetAutofillAgent()->FillFieldWithValue(mojo::String::From(value));
+ GetAutofillAgent()->FillFieldWithValue(value);
}
void ContentAutofillDriver::RendererShouldPreviewFieldWithValue(
const base::string16& value) {
if (!RendererIsAvailable())
return;
- GetAutofillAgent()->PreviewFieldWithValue(mojo::String::From(value));
+ GetAutofillAgent()->PreviewFieldWithValue(value);
}
void ContentAutofillDriver::PopupHidden() {
@@ -178,9 +176,9 @@ void ContentAutofillDriver::FirstUserGestureObserved() {
client_->OnFirstUserGestureObserved();
}
-void ContentAutofillDriver::FormsSeen(mojo::Array<FormData> forms,
+void ContentAutofillDriver::FormsSeen(const std::vector<FormData>& forms,
base::TimeTicks timestamp) {
- autofill_manager_->OnFormsSeen(forms.storage(), timestamp);
+ autofill_manager_->OnFormsSeen(forms, timestamp);
}
void ContentAutofillDriver::WillSubmitForm(const FormData& form,
@@ -231,10 +229,10 @@ void ContentAutofillDriver::DidEndTextFieldEditing() {
autofill_manager_->OnDidEndTextFieldEditing();
}
-void ContentAutofillDriver::SetDataList(mojo::Array<mojo::String> values,
- mojo::Array<mojo::String> labels) {
- autofill_manager_->OnSetDataList(values.To<std::vector<base::string16>>(),
- labels.To<std::vector<base::string16>>());
+void ContentAutofillDriver::SetDataList(
+ const std::vector<base::string16>& values,
+ const std::vector<base::string16>& labels) {
+ autofill_manager_->OnSetDataList(values, labels);
}
void ContentAutofillDriver::DidNavigateFrame(

Powered by Google App Engine
This is Rietveld 408576698