OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #ifndef ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ | 5 #ifndef ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ |
6 #define ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ | 6 #define ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ |
7 | 7 |
8 #include <jni.h> | 8 #include <jni.h> |
9 #include <list> | 9 #include <list> |
10 #include <string> | 10 #include <string> |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
204 | 204 |
205 // Sets the java delegate | 205 // Sets the java delegate |
206 void SetAwAutofillManagerDelegate(jobject delegate); | 206 void SetAwAutofillManagerDelegate(jobject delegate); |
207 | 207 |
208 void SetJsOnlineProperty(JNIEnv* env, jobject obj, jboolean network_up); | 208 void SetJsOnlineProperty(JNIEnv* env, jobject obj, jboolean network_up); |
209 void TrimMemory(JNIEnv* env, jobject obj, jint level, jboolean visible); | 209 void TrimMemory(JNIEnv* env, jobject obj, jint level, jboolean visible); |
210 | 210 |
211 private: | 211 private: |
212 void InitDataReductionProxyIfNecessary(); | 212 void InitDataReductionProxyIfNecessary(); |
213 void InitAutofillIfNecessary(bool enabled); | 213 void InitAutofillIfNecessary(bool enabled); |
214 void DidDrawGL(const DrawGLResult& result); | |
215 | 214 |
216 void InitializeHardwareDrawIfNeeded(); | 215 void InitializeHardwareDrawIfNeeded(); |
217 void InitializeHardwareDrawOnRenderThread(); | 216 void InitializeHardwareDrawOnRenderThread(); |
218 void ReleaseHardwareDrawOnRenderThread(); | 217 void ReleaseHardwareDrawOnRenderThread(); |
219 | 218 |
220 base::WeakPtrFactory<AwContents> weak_factory_on_ui_thread_; | |
221 base::WeakPtr<AwContents> ui_thread_weak_ptr_; | |
222 | |
223 JavaObjectWeakGlobalRef java_ref_; | 219 JavaObjectWeakGlobalRef java_ref_; |
224 scoped_ptr<content::WebContents> web_contents_; | 220 scoped_ptr<content::WebContents> web_contents_; |
225 scoped_ptr<AwWebContentsDelegate> web_contents_delegate_; | 221 scoped_ptr<AwWebContentsDelegate> web_contents_delegate_; |
226 scoped_ptr<AwContentsClientBridge> contents_client_bridge_; | 222 scoped_ptr<AwContentsClientBridge> contents_client_bridge_; |
227 scoped_ptr<AwRenderViewHostExt> render_view_host_ext_; | 223 scoped_ptr<AwRenderViewHostExt> render_view_host_ext_; |
228 scoped_ptr<FindHelper> find_helper_; | 224 scoped_ptr<FindHelper> find_helper_; |
229 scoped_ptr<IconHelper> icon_helper_; | 225 scoped_ptr<IconHelper> icon_helper_; |
230 scoped_ptr<AwContents> pending_contents_; | 226 scoped_ptr<AwContents> pending_contents_; |
231 SharedRendererState shared_renderer_state_; | 227 SharedRendererState shared_renderer_state_; |
232 BrowserViewRenderer browser_view_renderer_; | 228 BrowserViewRenderer browser_view_renderer_; |
(...skipping 11 matching lines...) Expand all Loading... |
244 GLViewRendererManager::Key renderer_manager_key_; | 240 GLViewRendererManager::Key renderer_manager_key_; |
245 | 241 |
246 DISALLOW_COPY_AND_ASSIGN(AwContents); | 242 DISALLOW_COPY_AND_ASSIGN(AwContents); |
247 }; | 243 }; |
248 | 244 |
249 bool RegisterAwContents(JNIEnv* env); | 245 bool RegisterAwContents(JNIEnv* env); |
250 | 246 |
251 } // namespace android_webview | 247 } // namespace android_webview |
252 | 248 |
253 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ | 249 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ |
OLD | NEW |