Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ | 5 #ifndef CHROME_BROWSER_UI_ANDROID_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ |
| 6 #define CHROME_BROWSER_UI_ANDROID_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ | 6 #define CHROME_BROWSER_UI_ANDROID_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ |
| 7 | 7 |
| 8 #include <jni.h> | |
| 9 | |
| 10 #include "base/android/scoped_java_ref.h" | |
| 8 #include "chrome/browser/ui/android/infobars/confirm_infobar.h" | 11 #include "chrome/browser/ui/android/infobars/confirm_infobar.h" |
| 9 | 12 |
| 10 class GroupedPermissionInfoBarDelegate; | 13 class GroupedPermissionInfoBarDelegate; |
| 11 | 14 |
| 12 class GroupedPermissionInfoBar : public ConfirmInfoBar { | 15 class GroupedPermissionInfoBar : public ConfirmInfoBar { |
| 13 public: | 16 public: |
| 14 explicit GroupedPermissionInfoBar( | 17 explicit GroupedPermissionInfoBar( |
| 15 std::unique_ptr<GroupedPermissionInfoBarDelegate> delegate); | 18 std::unique_ptr<GroupedPermissionInfoBarDelegate> delegate); |
| 16 ~GroupedPermissionInfoBar() override; | 19 ~GroupedPermissionInfoBar() override; |
| 17 | 20 |
| 21 void ToggleAccept(JNIEnv* env, | |
|
gone
2016/05/31 21:20:42
ToggleAccept is confusing. Sounds like something
tsergeant
2016/06/02 07:04:36
Done, changed to SetPermissionState
| |
| 22 const base::android::JavaParamRef<jobject>& obj, | |
| 23 jint position, | |
| 24 jboolean value); | |
| 25 | |
| 18 static bool Register(JNIEnv* env); | 26 static bool Register(JNIEnv* env); |
| 19 | 27 |
| 20 private: | 28 private: |
| 21 // InfoBarAndroid: | 29 // InfoBarAndroid: |
| 22 base::android::ScopedJavaLocalRef<jobject> CreateRenderInfoBar( | 30 base::android::ScopedJavaLocalRef<jobject> CreateRenderInfoBar( |
| 23 JNIEnv* env) override; | 31 JNIEnv* env) override; |
| 32 void SetJavaInfoBar( | |
| 33 const base::android::JavaRef<jobject>& java_info_bar) override; | |
| 24 | 34 |
| 25 GroupedPermissionInfoBarDelegate* GetDelegate(); | 35 GroupedPermissionInfoBarDelegate* GetDelegate(); |
| 26 | 36 |
| 27 DISALLOW_COPY_AND_ASSIGN(GroupedPermissionInfoBar); | 37 DISALLOW_COPY_AND_ASSIGN(GroupedPermissionInfoBar); |
| 28 }; | 38 }; |
| 29 | 39 |
| 30 #endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ | 40 #endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_GROUPED_PERMISSION_INFOBAR_H_ |
| OLD | NEW |