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

Side by Side Diff: components/web_contents_delegate_android/web_contents_delegate_android.cc

Issue 22314005: [Android] On calling openNewTab, pass the disposition instead of incognito. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: reverted copyright year update 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 unified diff | Download patch
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 #include "components/web_contents_delegate_android/web_contents_delegate_android .h" 5 #include "components/web_contents_delegate_android/web_contents_delegate_android .h"
6 6
7 #include <android/keycodes.h> 7 #include <android/keycodes.h>
8 8
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/jni_array.h" 10 #include "base/android/jni_array.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 env, 96 env,
97 reinterpret_cast<const uint8*>( 97 reinterpret_cast<const uint8*>(
98 params.browser_initiated_post_data.get()->front()), 98 params.browser_initiated_post_data.get()->front()),
99 params.browser_initiated_post_data.get()->size()); 99 params.browser_initiated_post_data.get()->size());
100 } 100 }
101 Java_WebContentsDelegateAndroid_openNewTab(env, 101 Java_WebContentsDelegateAndroid_openNewTab(env,
102 obj.obj(), 102 obj.obj(),
103 java_url.obj(), 103 java_url.obj(),
104 extra_headers.obj(), 104 extra_headers.obj(),
105 post_data.obj(), 105 post_data.obj(),
106 disposition == OFF_THE_RECORD); 106 disposition);
107 return NULL; 107 return NULL;
108 } 108 }
109 109
110 source->GetController().LoadURL(url, params.referrer, transition, 110 source->GetController().LoadURL(url, params.referrer, transition,
111 std::string()); 111 std::string());
112 return source; 112 return source;
113 } 113 }
114 114
115 void WebContentsDelegateAndroid::NavigationStateChanged( 115 void WebContentsDelegateAndroid::NavigationStateChanged(
116 const WebContents* source, unsigned changed_flags) { 116 const WebContents* source, unsigned changed_flags) {
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 352
353 bool RegisterWebContentsDelegateAndroid(JNIEnv* env) { 353 bool RegisterWebContentsDelegateAndroid(JNIEnv* env) {
354 if (!HasClass(env, kWebContentsDelegateAndroidClassPath)) { 354 if (!HasClass(env, kWebContentsDelegateAndroidClassPath)) {
355 DLOG(ERROR) << "Unable to find class WebContentsDelegateAndroid!"; 355 DLOG(ERROR) << "Unable to find class WebContentsDelegateAndroid!";
356 return false; 356 return false;
357 } 357 }
358 return RegisterNativesImpl(env); 358 return RegisterNativesImpl(env);
359 } 359 }
360 360
361 } // namespace web_contents_delegate_android 361 } // namespace web_contents_delegate_android
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698