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

Unified Diff: chrome/android/testshell/testshell_tab.cc

Issue 23020009: TabBase: Add ContentView/NativePage ownership (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase! Created 7 years, 4 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
« no previous file with comments | « chrome/android/testshell/testshell_tab.h ('k') | chrome/browser/android/shortcut_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/testshell/testshell_tab.cc
diff --git a/chrome/android/testshell/testshell_tab.cc b/chrome/android/testshell/testshell_tab.cc
index 568190dfa77b361e220d863712b800f5f36aecbe..d9101c854455f8753cb03fa778925f2061ab1e3b 100644
--- a/chrome/android/testshell/testshell_tab.cc
+++ b/chrome/android/testshell/testshell_tab.cc
@@ -24,14 +24,8 @@ using content::WebContents;
using ui::WindowAndroid;
TestShellTab::TestShellTab(JNIEnv* env,
- jobject obj,
- WebContents* web_contents,
- WindowAndroid* window_android)
- : TabAndroid(env, obj),
- web_contents_(web_contents) {
- InitTabHelpers(web_contents);
- WindowAndroidHelper::FromWebContents(web_contents)->
- SetWindowAndroid(window_android);
+ jobject obj)
+ : TabAndroid(env, obj) {
}
TestShellTab::~TestShellTab() {
@@ -41,10 +35,6 @@ void TestShellTab::Destroy(JNIEnv* env, jobject obj) {
delete this;
}
-WebContents* TestShellTab::GetWebContents() {
- return web_contents_.get();
-}
-
browser_sync::SyncedTabDelegate* TestShellTab::GetSyncedTabDelegate() {
NOTIMPLEMENTED();
return NULL;
@@ -106,15 +96,6 @@ bool TestShellTab::RegisterTestShellTab(JNIEnv* env) {
return RegisterNativesImpl(env);
}
-void TestShellTab::InitWebContentsDelegate(
- JNIEnv* env,
- jobject obj,
- jobject web_contents_delegate) {
- web_contents_delegate_.reset(
- new ChromeWebContentsDelegateAndroid(env, web_contents_delegate));
- web_contents_->SetDelegate(web_contents_delegate_.get());
-}
-
ScopedJavaLocalRef<jstring> TestShellTab::FixupUrl(JNIEnv* env,
jobject obj,
jstring url) {
@@ -128,16 +109,8 @@ ScopedJavaLocalRef<jstring> TestShellTab::FixupUrl(JNIEnv* env,
return ConvertUTF8ToJavaString(env, fixed_spec);
}
-static jint Init(JNIEnv* env,
- jobject obj,
- jint web_contents_ptr,
- jint window_android_ptr) {
- TestShellTab* tab = new TestShellTab(
- env,
- obj,
- reinterpret_cast<WebContents*>(web_contents_ptr),
- reinterpret_cast<WindowAndroid*>(window_android_ptr));
- return reinterpret_cast<jint>(tab);
+static jint Init(JNIEnv* env, jobject obj) {
+ return reinterpret_cast<jint>(new TestShellTab(env, obj));
}
int TestShellTab::GetSyncId() const {
« no previous file with comments | « chrome/android/testshell/testshell_tab.h ('k') | chrome/browser/android/shortcut_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698