Chromium Code Reviews| Index: chrome/browser/ui/android/infobars/autofill_cc_infobar.h |
| diff --git a/chrome/browser/ui/android/infobars/autofill_cc_infobar.h b/chrome/browser/ui/android/infobars/autofill_cc_infobar.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..00fb8c8060aeb4893698e7618134a513f05048e6 |
| --- /dev/null |
| +++ b/chrome/browser/ui/android/infobars/autofill_cc_infobar.h |
| @@ -0,0 +1,39 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CHROME_BROWSER_UI_ANDROID_INFOBARS_AUTOFILL_CC_INFOBAR_H_ |
| +#define CHROME_BROWSER_UI_ANDROID_INFOBARS_AUTOFILL_CC_INFOBAR_H_ |
| + |
| +#include <jni.h> |
| + |
| +#include "base/macros.h" |
| +#include "base/memory/scoped_ptr.h" |
| +#include "chrome/browser/ui/android/infobars/confirm_infobar.h" |
| + |
| +namespace autofill { |
| +class AutofillCCInfoBarDelegate; |
| +} |
| + |
| +// Android implementation of the infobar for saving credit card information. |
| +class AutofillCCInfoBar : public ConfirmInfoBar { |
| + public: |
| + // Register the JNI bindings. |
|
Peter Kasting
2016/01/08 00:34:31
Function comments should be declarative ("Register
please use gerrit instead
2016/01/12 00:47:25
Done.
|
| + static bool Register(JNIEnv* env); |
|
Peter Kasting
2016/01/08 00:34:31
Nit: Per Google style guide, static methods go aft
please use gerrit instead
2016/01/12 00:47:25
Done.
|
| + |
| + explicit AutofillCCInfoBar( |
| + scoped_ptr<autofill::AutofillCCInfoBarDelegate> delegate); |
| + ~AutofillCCInfoBar() override; |
| + |
| + // Called when a link in the legal message text was clicked. |
| + void OnLegalMessageLinkClicked(JNIEnv* env, jobject obj, jstring url); |
| + |
| + private: |
| + // ConfirmInfoBar override. |
| + base::android::ScopedJavaLocalRef<jobject> CreateRenderInfoBar( |
| + JNIEnv* env) override; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(AutofillCCInfoBar); |
| +}; |
| + |
| +#endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_AUTOFILL_CC_INFOBAR_H_ |