| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #include "chrome/browser/ui/android/website_settings_popup_android.h" | 5 #include "chrome/browser/ui/android/website_settings_popup_android.h" |
| 6 | 6 |
| 7 #include "base/android/jni_android.h" | 7 #include "base/android/jni_android.h" |
| 8 #include "base/android/jni_array.h" | 8 #include "base/android/jni_array.h" |
| 9 #include "base/android/jni_string.h" | 9 #include "base/android/jni_string.h" |
| 10 #include "chrome/browser/infobars/infobar_service.h" | 10 #include "chrome/browser/infobars/infobar_service.h" |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 content::CertStore::GetInstance())); | 63 content::CertStore::GetInstance())); |
| 64 } | 64 } |
| 65 | 65 |
| 66 WebsiteSettingsPopupAndroid::~WebsiteSettingsPopupAndroid() {} | 66 WebsiteSettingsPopupAndroid::~WebsiteSettingsPopupAndroid() {} |
| 67 | 67 |
| 68 void WebsiteSettingsPopupAndroid::Destroy(JNIEnv* env, | 68 void WebsiteSettingsPopupAndroid::Destroy(JNIEnv* env, |
| 69 const JavaParamRef<jobject>& obj) { | 69 const JavaParamRef<jobject>& obj) { |
| 70 delete this; | 70 delete this; |
| 71 } | 71 } |
| 72 | 72 |
| 73 void WebsiteSettingsPopupAndroid::RecordWebsiteSettingsAction( |
| 74 JNIEnv* env, |
| 75 const JavaParamRef<jobject>& obj, |
| 76 jint action) { |
| 77 presenter_->RecordWebsiteSettingsAction( |
| 78 static_cast<WebsiteSettings::WebsiteSettingsAction>(action)); |
| 79 } |
| 80 |
| 73 void WebsiteSettingsPopupAndroid::SetIdentityInfo( | 81 void WebsiteSettingsPopupAndroid::SetIdentityInfo( |
| 74 const IdentityInfo& identity_info) { | 82 const IdentityInfo& identity_info) { |
| 75 JNIEnv* env = base::android::AttachCurrentThread(); | 83 JNIEnv* env = base::android::AttachCurrentThread(); |
| 76 Java_WebsiteSettingsPopup_showDialog(env, popup_jobject_.obj()); | 84 Java_WebsiteSettingsPopup_showDialog(env, popup_jobject_.obj()); |
| 77 } | 85 } |
| 78 | 86 |
| 79 void WebsiteSettingsPopupAndroid::SetCookieInfo( | 87 void WebsiteSettingsPopupAndroid::SetCookieInfo( |
| 80 const CookieInfoList& cookie_info_list) { | 88 const CookieInfoList& cookie_info_list) { |
| 81 NOTIMPLEMENTED(); | 89 NOTIMPLEMENTED(); |
| 82 } | 90 } |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 WebsiteSettingsUI::TabId tab_id) { | 141 WebsiteSettingsUI::TabId tab_id) { |
| 134 // There's no tab UI on Android - only connection info is shown. | 142 // There's no tab UI on Android - only connection info is shown. |
| 135 NOTIMPLEMENTED(); | 143 NOTIMPLEMENTED(); |
| 136 } | 144 } |
| 137 | 145 |
| 138 // static | 146 // static |
| 139 bool WebsiteSettingsPopupAndroid::RegisterWebsiteSettingsPopupAndroid( | 147 bool WebsiteSettingsPopupAndroid::RegisterWebsiteSettingsPopupAndroid( |
| 140 JNIEnv* env) { | 148 JNIEnv* env) { |
| 141 return RegisterNativesImpl(env); | 149 return RegisterNativesImpl(env); |
| 142 } | 150 } |
| OLD | NEW |