OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/android/tab_android.h" | 5 #include "chrome/browser/android/tab_android.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/android/jni_android.h" | 9 #include "base/android/jni_android.h" |
10 #include "base/android/jni_string.h" | 10 #include "base/android/jni_string.h" |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 #include "ui/base/resource/resource_bundle.h" | 84 #include "ui/base/resource/resource_bundle.h" |
85 #include "ui/base/window_open_disposition.h" | 85 #include "ui/base/window_open_disposition.h" |
86 #include "ui/display/display.h" | 86 #include "ui/display/display.h" |
87 #include "ui/display/screen.h" | 87 #include "ui/display/screen.h" |
88 #include "ui/gfx/android/java_bitmap.h" | 88 #include "ui/gfx/android/java_bitmap.h" |
89 #include "ui/gfx/favicon_size.h" | 89 #include "ui/gfx/favicon_size.h" |
90 #include "ui/gfx/image/image_skia.h" | 90 #include "ui/gfx/image/image_skia.h" |
91 | 91 |
92 using base::android::AttachCurrentThread; | 92 using base::android::AttachCurrentThread; |
93 using base::android::ConvertUTF8ToJavaString; | 93 using base::android::ConvertUTF8ToJavaString; |
| 94 using base::android::JavaParamRef; |
94 using content::BrowserThread; | 95 using content::BrowserThread; |
95 using content::GlobalRequestID; | 96 using content::GlobalRequestID; |
96 using content::NavigationController; | 97 using content::NavigationController; |
97 using content::WebContents; | 98 using content::WebContents; |
98 using navigation_interception::InterceptNavigationDelegate; | 99 using navigation_interception::InterceptNavigationDelegate; |
99 using navigation_interception::NavigationParams; | 100 using navigation_interception::NavigationParams; |
100 | 101 |
101 TabAndroid* TabAndroid::FromWebContents( | 102 TabAndroid* TabAndroid::FromWebContents( |
102 const content::WebContents* web_contents) { | 103 const content::WebContents* web_contents) { |
103 const CoreTabHelper* core_tab_helper = CoreTabHelper::FromWebContents( | 104 const CoreTabHelper* core_tab_helper = CoreTabHelper::FromWebContents( |
(...skipping 789 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
893 static void Init(JNIEnv* env, const JavaParamRef<jobject>& obj) { | 894 static void Init(JNIEnv* env, const JavaParamRef<jobject>& obj) { |
894 TRACE_EVENT0("native", "TabAndroid::Init"); | 895 TRACE_EVENT0("native", "TabAndroid::Init"); |
895 // This will automatically bind to the Java object and pass ownership there. | 896 // This will automatically bind to the Java object and pass ownership there. |
896 new TabAndroid(env, obj); | 897 new TabAndroid(env, obj); |
897 } | 898 } |
898 | 899 |
899 // static | 900 // static |
900 bool TabAndroid::RegisterTabAndroid(JNIEnv* env) { | 901 bool TabAndroid::RegisterTabAndroid(JNIEnv* env) { |
901 return RegisterNativesImpl(env); | 902 return RegisterNativesImpl(env); |
902 } | 903 } |
OLD | NEW |