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

Side by Side Diff: chrome/browser/ui/android/autofill/card_unmask_prompt_view_android.h

Issue 1138653003: Move card unmask interfaces and controller into the autofill component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix missing override declaration Created 5 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_ 5 #ifndef CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_
6 #define CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_ 6 #define CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 9
10 #include "base/android/jni_string.h" 10 #include "base/android/jni_string.h"
11 #include "base/android/scoped_java_ref.h" 11 #include "base/android/scoped_java_ref.h"
12 #include "base/strings/string16.h" 12 #include "base/strings/string16.h"
13 #include "chrome/browser/ui/autofill/card_unmask_prompt_view.h" 13 #include "components/autofill/core/browser/ui/card_unmask_prompt_view.h"
14
15 namespace content {
16 class WebContents;
17 }
14 18
15 namespace autofill { 19 namespace autofill {
16 20
17 class CardUnmaskPromptViewAndroid : public CardUnmaskPromptView { 21 class CardUnmaskPromptViewAndroid : public CardUnmaskPromptView {
18 public: 22 public:
19 explicit CardUnmaskPromptViewAndroid(CardUnmaskPromptController* controller); 23 explicit CardUnmaskPromptViewAndroid(CardUnmaskPromptController* controller,
20 24 content::WebContents* web_contents);
21 void Show();
22 25
23 bool CheckUserInputValidity(JNIEnv* env, jobject obj, jstring response); 26 bool CheckUserInputValidity(JNIEnv* env, jobject obj, jstring response);
24 void OnUserInput(JNIEnv* env, 27 void OnUserInput(JNIEnv* env,
25 jobject obj, 28 jobject obj,
26 jstring cvc, 29 jstring cvc,
27 jstring month, 30 jstring month,
28 jstring year, 31 jstring year,
29 jboolean should_store_locally); 32 jboolean should_store_locally);
30 void PromptDismissed(JNIEnv* env, jobject obj); 33 void PromptDismissed(JNIEnv* env, jobject obj);
31 34
32 // CardUnmaskPromptView implementation. 35 // CardUnmaskPromptView implementation.
36 void Show() override;
33 void ControllerGone() override; 37 void ControllerGone() override;
34 void DisableAndWaitForVerification() override; 38 void DisableAndWaitForVerification() override;
35 void GotVerificationResult(const base::string16& error_message, 39 void GotVerificationResult(const base::string16& error_message,
36 bool allow_retry) override; 40 bool allow_retry) override;
37 41
38 static bool Register(JNIEnv* env); 42 static bool Register(JNIEnv* env);
39 43
40 private: 44 private:
41 ~CardUnmaskPromptViewAndroid() override; 45 ~CardUnmaskPromptViewAndroid() override;
42 46
43 // The corresponding java object. 47 // The corresponding java object.
44 base::android::ScopedJavaGlobalRef<jobject> java_object_; 48 base::android::ScopedJavaGlobalRef<jobject> java_object_;
45 49
46 CardUnmaskPromptController* controller_; 50 CardUnmaskPromptController* controller_;
51 content::WebContents* web_contents_;
47 52
48 DISALLOW_COPY_AND_ASSIGN(CardUnmaskPromptViewAndroid); 53 DISALLOW_COPY_AND_ASSIGN(CardUnmaskPromptViewAndroid);
49 }; 54 };
50 55
51 } // namespace autofill 56 } // namespace autofill
52 57
53 #endif // CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_ 58 #endif // CHROME_BROWSER_UI_ANDROID_AUTOFILL_CARD_UNMASK_PROMPT_VIEW_ANDROID_H_
OLDNEW
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | chrome/browser/ui/android/autofill/card_unmask_prompt_view_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698