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

Unified Diff: android_webview/native/aw_autofill_client.cc

Issue 1582353006: CountryNames: Separate data creation from usage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@571610_exposeCountryNamesToTesting
Patch Set: More Android fixes Created 4 years, 11 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: android_webview/native/aw_autofill_client.cc
diff --git a/android_webview/native/aw_autofill_client.cc b/android_webview/native/aw_autofill_client.cc
index b72eb14b247662754d4b7220116b3fd8bd9a0691..30f1b28d58525948cf25e8858008133b40809e2b 100644
--- a/android_webview/native/aw_autofill_client.cc
+++ b/android_webview/native/aw_autofill_client.cc
@@ -12,6 +12,7 @@
#include "base/android/jni_android.h"
#include "base/android/jni_string.h"
#include "base/android/scoped_java_ref.h"
+#include "base/i18n/rtl.h"
#include "base/logging.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
@@ -40,7 +41,9 @@ namespace android_webview {
// autofill functionality at the java side. The java peer is owned by Java
// AwContents. The native object only maintains a weak ref to it.
AwAutofillClient::AwAutofillClient(WebContents* contents)
- : web_contents_(contents), save_form_data_(false) {
+ : web_contents_(contents),
+ save_form_data_(false),
+ application_locale_(base::i18n::GetConfiguredLocale()) {
JNIEnv* env = AttachCurrentThread();
ScopedJavaLocalRef<jobject> delegate;
delegate.Reset(
@@ -197,6 +200,10 @@ bool AwAutofillClient::IsContextSecure(const GURL& form_origin) {
ssl_status.content_status == content::SSLStatus::NORMAL_CONTENT;
}
+const std::string& AwAutofillClient::GetApplicationLocale() {
+ return application_locale_;
+}
+
void AwAutofillClient::SuggestionSelected(JNIEnv* env,
const JavaParamRef<jobject>& object,
jint position) {

Powered by Google App Engine
This is Rietveld 408576698