| OLD | NEW | 
|   1 // Copyright 2015 The Chromium Authors. All rights reserved. |   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 |   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_CONNECTION_INFO_POPUP_ANDROID_H_ |   5 #ifndef CHROME_BROWSER_UI_ANDROID_CONNECTION_INFO_POPUP_ANDROID_H_ | 
|   6 #define CHROME_BROWSER_UI_ANDROID_CONNECTION_INFO_POPUP_ANDROID_H_ |   6 #define CHROME_BROWSER_UI_ANDROID_CONNECTION_INFO_POPUP_ANDROID_H_ | 
|   7  |   7  | 
|   8 #include <jni.h> |   8 #include <jni.h> | 
|   9  |   9  | 
|  10 #include "base/android/scoped_java_ref.h" |  10 #include "base/android/scoped_java_ref.h" | 
|  11 #include "base/basictypes.h" |  11 #include "base/basictypes.h" | 
|  12 #include "base/memory/scoped_ptr.h" |  12 #include "base/memory/scoped_ptr.h" | 
|  13 #include "chrome/browser/ui/website_settings/website_settings_ui.h" |  13 #include "chrome/browser/ui/website_settings/website_settings_ui.h" | 
|  14  |  14  | 
|  15 namespace content { |  15 namespace content { | 
|  16 class WebContents; |  16 class WebContents; | 
|  17 } |  17 } | 
|  18  |  18  | 
|  19 // Android implementation of the website settings UI which displays detailed |  19 // Android implementation of the website settings UI which displays detailed | 
|  20 // connection and certificate information for the website. |  20 // connection and certificate information for the website. | 
|  21 class ConnectionInfoPopupAndroid : public WebsiteSettingsUI { |  21 class ConnectionInfoPopupAndroid : public WebsiteSettingsUI { | 
|  22  public: |  22  public: | 
|  23   ConnectionInfoPopupAndroid(JNIEnv* env, |  23   ConnectionInfoPopupAndroid(JNIEnv* env, | 
|  24                              jobject java_website_settings, |  24                              jobject java_website_settings, | 
|  25                              content::WebContents* web_contents); |  25                              content::WebContents* web_contents); | 
|  26   ~ConnectionInfoPopupAndroid() override; |  26   ~ConnectionInfoPopupAndroid() override; | 
|  27   void Destroy(JNIEnv* env, jobject obj); |  27   void Destroy(JNIEnv* env, const base::android::JavaParamRef<jobject>& obj); | 
|  28  |  28  | 
|  29   // Revokes any current user exceptions for bypassing SSL error interstitials |  29   // Revokes any current user exceptions for bypassing SSL error interstitials | 
|  30   // on this page. |  30   // on this page. | 
|  31   void ResetCertDecisions(JNIEnv* env, jobject obj, jobject java_web_contents); |  31   void ResetCertDecisions( | 
 |  32       JNIEnv* env, | 
 |  33       const base::android::JavaParamRef<jobject>& obj, | 
 |  34       const base::android::JavaParamRef<jobject>& java_web_contents); | 
|  32  |  35  | 
|  33   // WebsiteSettingsUI implementations. |  36   // WebsiteSettingsUI implementations. | 
|  34   void SetCookieInfo(const CookieInfoList& cookie_info_list) override; |  37   void SetCookieInfo(const CookieInfoList& cookie_info_list) override; | 
|  35   void SetPermissionInfo( |  38   void SetPermissionInfo( | 
|  36       const PermissionInfoList& permission_info_list) override; |  39       const PermissionInfoList& permission_info_list) override; | 
|  37   void SetIdentityInfo(const IdentityInfo& identity_info) override; |  40   void SetIdentityInfo(const IdentityInfo& identity_info) override; | 
|  38   void SetSelectedTab(WebsiteSettingsUI::TabId tab_id) override; |  41   void SetSelectedTab(WebsiteSettingsUI::TabId tab_id) override; | 
|  39  |  42  | 
|  40   static bool RegisterConnectionInfoPopupAndroid(JNIEnv* env); |  43   static bool RegisterConnectionInfoPopupAndroid(JNIEnv* env); | 
|  41  |  44  | 
|  42  private: |  45  private: | 
|  43   // The presenter that controlls the Website Settings UI. |  46   // The presenter that controlls the Website Settings UI. | 
|  44   scoped_ptr<WebsiteSettings> presenter_; |  47   scoped_ptr<WebsiteSettings> presenter_; | 
|  45  |  48  | 
|  46   // The java prompt implementation. |  49   // The java prompt implementation. | 
|  47   base::android::ScopedJavaGlobalRef<jobject> popup_jobject_; |  50   base::android::ScopedJavaGlobalRef<jobject> popup_jobject_; | 
|  48  |  51  | 
|  49   DISALLOW_COPY_AND_ASSIGN(ConnectionInfoPopupAndroid); |  52   DISALLOW_COPY_AND_ASSIGN(ConnectionInfoPopupAndroid); | 
|  50 }; |  53 }; | 
|  51  |  54  | 
|  52 #endif  // CHROME_BROWSER_UI_ANDROID_CONNECTION_INFO_POPUP_ANDROID_H_ |  55 #endif  // CHROME_BROWSER_UI_ANDROID_CONNECTION_INFO_POPUP_ANDROID_H_ | 
| OLD | NEW |