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

Unified Diff: content/browser/android/content_view_core_impl.h

Issue 9192008: Hook up ContentViewCore.add/removeJavascriptInterface() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Modify ContentViewCoreImpl to use WebContentsImpl Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/android/content_view_core_impl.h
diff --git a/content/browser/android/content_view_core_impl.h b/content/browser/android/content_view_core_impl.h
index 3e04591a08e8dd8d3bd9faa9d290f7da13f5ca53..97006f1d8f6f7291a5ec1de742cf9c3b9dc31131 100644
--- a/content/browser/android/content_view_core_impl.h
+++ b/content/browser/android/content_view_core_impl.h
@@ -13,6 +13,7 @@
#include "base/i18n/rtl.h"
#include "base/memory/scoped_ptr.h"
#include "base/process.h"
+#include "content/browser/web_contents/web_contents_impl.h"
#include "content/public/browser/android/content_view_core.h"
#include "content/public/browser/notification_observer.h"
#include "googleurl/src/gurl.h"
@@ -31,7 +32,17 @@ class ContentViewCoreImpl : public ContentViewCore,
ContentViewCoreImpl(JNIEnv* env,
jobject obj,
WebContents* web_contents);
- virtual void Destroy(JNIEnv* env, jobject obj);
+
+ // ContentViewCore overrides
+ virtual void Destroy(JNIEnv* env, jobject obj) OVERRIDE;
+ virtual void AddJavascriptInterface(
+ JNIEnv* env,
+ jobject obj,
+ jobject object,
+ jstring name,
+ jboolean allow_inherited_methods) OVERRIDE;
+ virtual void RemoveJavascriptInterface(JNIEnv* env, jobject obj,
+ jstring name) OVERRIDE;
// --------------------------------------------------------------------------
// Methods called from Java via JNI
@@ -107,7 +118,7 @@ class ContentViewCoreImpl : public ContentViewCore,
gfx::Rect GetBounds() const;
- WebContents* web_contents() const { return web_contents_; }
+ WebContents* web_contents() const { return web_contents_impl_; }
void LoadUrl(const GURL& url, int page_transition);
void LoadUrlWithUserAgentOverride(
const GURL& url,
@@ -138,7 +149,7 @@ class ContentViewCoreImpl : public ContentViewCore,
// Reference to the current WebContents used to determine how and what to
// display in the ContentViewCore.
- WebContents* web_contents_;
+ WebContentsImpl* web_contents_impl_;
// We only set this to be the delegate of the web_contents if we own it.
scoped_ptr<ContentViewClient> content_view_client_;
« no previous file with comments | « no previous file | content/browser/android/content_view_core_impl.cc » ('j') | content/browser/android/content_view_core_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698