Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1597)

Side by Side Diff: android_webview/native/aw_contents.h

Issue 12207061: Add a utility method to receive an AwContents (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add a DCHECK Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | android_webview/native/aw_contents.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <string> 9 #include <string>
10 10
(...skipping 30 matching lines...) Expand all
41 // WebView functionality; analogous to chrome's TabContents, but with a 41 // WebView functionality; analogous to chrome's TabContents, but with a
42 // level of indirection provided by the AwContentsContainer abstraction. 42 // level of indirection provided by the AwContentsContainer abstraction.
43 class AwContents : public FindHelper::Listener, 43 class AwContents : public FindHelper::Listener,
44 public IconHelper::Listener, 44 public IconHelper::Listener,
45 public content::Compositor::Client, 45 public content::Compositor::Client,
46 public AwRenderViewHostExt::Client { 46 public AwRenderViewHostExt::Client {
47 public: 47 public:
48 // Returns the AwContents instance associated with |web_contents|, or NULL. 48 // Returns the AwContents instance associated with |web_contents|, or NULL.
49 static AwContents* FromWebContents(content::WebContents* web_contents); 49 static AwContents* FromWebContents(content::WebContents* web_contents);
50 50
51 // Returns the AwContents instance associated with with the given
52 // render_process_id and render_view_id, or NULL.
53 static AwContents* FromID(int render_process_id, int render_view_id);
54
51 AwContents(JNIEnv* env, 55 AwContents(JNIEnv* env,
52 jobject obj, 56 jobject obj,
53 jobject web_contents_delegate); 57 jobject web_contents_delegate);
54 virtual ~AwContents(); 58 virtual ~AwContents();
55 59
56 void DrawGL(AwDrawGLInfo* draw_info); 60 void DrawGL(AwDrawGLInfo* draw_info);
57 bool DrawSW(JNIEnv* env, jobject obj, jobject canvas); 61 bool DrawSW(JNIEnv* env, jobject obj, jobject canvas);
58 62
59 void RunJavaScriptDialog( 63 void RunJavaScriptDialog(
60 content::JavaScriptMessageType message_type, 64 content::JavaScriptMessageType message_type,
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 EGLContext last_frame_context_; 176 EGLContext last_frame_context_;
173 177
174 DISALLOW_COPY_AND_ASSIGN(AwContents); 178 DISALLOW_COPY_AND_ASSIGN(AwContents);
175 }; 179 };
176 180
177 bool RegisterAwContents(JNIEnv* env); 181 bool RegisterAwContents(JNIEnv* env);
178 182
179 } // namespace android_webview 183 } // namespace android_webview
180 184
181 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ 185 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_
OLDNEW
« no previous file with comments | « no previous file | android_webview/native/aw_contents.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698