| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ | 5 #ifndef CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ |
| 6 #define CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ | 6 #define CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/android/scoped_java_ref.h" | 10 #include "base/android/scoped_java_ref.h" |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 | 40 |
| 41 virtual void SetJavaInfoBar( | 41 virtual void SetJavaInfoBar( |
| 42 const base::android::JavaRef<jobject>& java_info_bar); | 42 const base::android::JavaRef<jobject>& java_info_bar); |
| 43 jobject GetJavaInfoBar(); | 43 jobject GetJavaInfoBar(); |
| 44 bool HasSetJavaInfoBar() const; | 44 bool HasSetJavaInfoBar() const; |
| 45 | 45 |
| 46 // Tells the Java-side counterpart of this InfoBar to point to the replacement | 46 // Tells the Java-side counterpart of this InfoBar to point to the replacement |
| 47 // InfoBar instead of this one. | 47 // InfoBar instead of this one. |
| 48 void ReassignJavaInfoBar(InfoBarAndroid* replacement); | 48 void ReassignJavaInfoBar(InfoBarAndroid* replacement); |
| 49 | 49 |
| 50 int GetInfoBarIdentifier(JNIEnv* env, |
| 51 const base::android::JavaParamRef<jobject>& obj); |
| 50 virtual void OnLinkClicked(JNIEnv* env, | 52 virtual void OnLinkClicked(JNIEnv* env, |
| 51 const base::android::JavaParamRef<jobject>& obj) {} | 53 const base::android::JavaParamRef<jobject>& obj) {} |
| 52 void OnButtonClicked(JNIEnv* env, | 54 void OnButtonClicked(JNIEnv* env, |
| 53 const base::android::JavaParamRef<jobject>& obj, | 55 const base::android::JavaParamRef<jobject>& obj, |
| 54 jint action); | 56 jint action); |
| 55 void OnCloseButtonClicked(JNIEnv* env, | 57 void OnCloseButtonClicked(JNIEnv* env, |
| 56 const base::android::JavaParamRef<jobject>& obj); | 58 const base::android::JavaParamRef<jobject>& obj); |
| 57 | 59 |
| 58 void CloseJavaInfoBar(); | 60 void CloseJavaInfoBar(); |
| 59 | 61 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 76 private: | 78 private: |
| 77 base::android::ScopedJavaGlobalRef<jobject> java_info_bar_; | 79 base::android::ScopedJavaGlobalRef<jobject> java_info_bar_; |
| 78 | 80 |
| 79 DISALLOW_COPY_AND_ASSIGN(InfoBarAndroid); | 81 DISALLOW_COPY_AND_ASSIGN(InfoBarAndroid); |
| 80 }; | 82 }; |
| 81 | 83 |
| 82 // Registers the NativeInfoBar's native methods through JNI. | 84 // Registers the NativeInfoBar's native methods through JNI. |
| 83 bool RegisterNativeInfoBar(JNIEnv* env); | 85 bool RegisterNativeInfoBar(JNIEnv* env); |
| 84 | 86 |
| 85 #endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ | 87 #endif // CHROME_BROWSER_UI_ANDROID_INFOBARS_INFOBAR_ANDROID_H_ |
| OLD | NEW |