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

Side by Side Diff: chrome/browser/ui/android/infobars/permission_group_infobar_android.h

Issue 1332063003: permissions: implement coalesced permissions on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@request-multiple
Patch Set: Address review comment Created 5 years, 2 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_ANDROID_INFOBARS_PERMISSION_GROUP_INFOBAR_ANDROID_H_
6 #define CHROME_BROWSER_UI_ANDROID_INFOBARS_PERMISSION_GROUP_INFOBAR_ANDROID_H_
7
8 #include "base/android/scoped_java_ref.h"
9 #include "base/basictypes.h"
10 #include "chrome/browser/ui/android/infobars/confirm_infobar.h"
11
12 class PermissionGroupInfoBarDelegateAndroid;
13
14 // Infobar which are shown when a website requests multiple permissions at the
15 // same time.
16 class PermissionGroupInfoBarAndroid : public ConfirmInfoBar {
17 public:
18 PermissionGroupInfoBarAndroid(
19 scoped_ptr<PermissionGroupInfoBarDelegateAndroid> delegate,
20 std::vector<int> permission_types);
21 ~PermissionGroupInfoBarAndroid() override;
22
23 void OnCheckedStateUpdate(JNIEnv* env,
24 jobject obj,
25 jbooleanArray checkedState);
26
27 private:
28 // InfoBarAndroid overrides.
29 base::android::ScopedJavaLocalRef<jobject> CreateRenderInfoBar(
30 JNIEnv* env) override;
31
32 PermissionGroupInfoBarDelegateAndroid* GetDelegate();
33
34 std::vector<int> permission_types_;
35
36 base::android::ScopedJavaGlobalRef<jobject> java_infobar_;
37
38 DISALLOW_COPY_AND_ASSIGN(PermissionGroupInfoBarAndroid);
39 };
40
41 // Register native methods.
42 bool RegisterPermissionGroupInfoBarAndroid(JNIEnv* env);
43
44 #endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_PERMISSION_GROUP_INFOBAR_ANDROID_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698