| Index: content/browser/android/web_contents_observer_proxy.cc
|
| diff --git a/content/browser/android/web_contents_observer_proxy.cc b/content/browser/android/web_contents_observer_proxy.cc
|
| index e6a4c9dd69fe76a10ee805294bb50b2b84846257..bc068304e2716d0a6de2ce45d4bb99e0aab49275 100644
|
| --- a/content/browser/android/web_contents_observer_proxy.cc
|
| +++ b/content/browser/android/web_contents_observer_proxy.cc
|
| @@ -81,17 +81,6 @@ void WebContentsObserverProxy::RenderProcessGone(
|
| Java_WebContentsObserverProxy_renderProcessGone(env, obj, was_oom_protected);
|
| }
|
|
|
| -void WebContentsObserverProxy::DidFinishNavigation(
|
| - NavigationHandle* navigation_handle) {
|
| - JNIEnv* env = AttachCurrentThread();
|
| - ScopedJavaLocalRef<jobject> obj(java_observer_);
|
| - ScopedJavaLocalRef<jstring> jstring_url(
|
| - ConvertUTF8ToJavaString(env, web_contents()->GetVisibleURL().spec()));
|
| - Java_WebContentsObserverProxy_didFinishNavigation(
|
| - env, obj, navigation_handle->IsInMainFrame(),
|
| - navigation_handle->IsErrorPage(), navigation_handle->HasCommitted());
|
| -}
|
| -
|
| void WebContentsObserverProxy::DidStartLoading() {
|
| JNIEnv* env = AttachCurrentThread();
|
| ScopedJavaLocalRef<jobject> obj(java_observer_);
|
| @@ -219,6 +208,33 @@ void WebContentsObserverProxy::DidCommitProvisionalLoadForFrame(
|
| !render_frame_host->GetParent(), jstring_url, transition_type);
|
| }
|
|
|
| +void WebContentsObserverProxy::DidStartNavigation(
|
| + NavigationHandle* navigation_handle) {
|
| + JNIEnv* env = AttachCurrentThread();
|
| + ScopedJavaLocalRef<jobject> obj(java_observer_);
|
| + ScopedJavaLocalRef<jstring> jstring_url(
|
| + ConvertUTF8ToJavaString(env, navigation_handle->GetURL().spec()));
|
| + Java_WebContentsObserverProxy_didStartNavigation(
|
| + env, obj, jstring_url, navigation_handle->IsInMainFrame(),
|
| + navigation_handle->IsErrorPage());
|
| +}
|
| +
|
| +void WebContentsObserverProxy::DidFinishNavigation(
|
| + NavigationHandle* navigation_handle) {
|
| + JNIEnv* env = AttachCurrentThread();
|
| + ScopedJavaLocalRef<jobject> obj(java_observer_);
|
| + ScopedJavaLocalRef<jstring> jstring_url(
|
| + ConvertUTF8ToJavaString(env, navigation_handle->GetURL().spec()));
|
| +
|
| + Java_WebContentsObserverProxy_didFinishNavigation(
|
| + env, obj, jstring_url, navigation_handle->IsInMainFrame(),
|
| + navigation_handle->IsErrorPage(), navigation_handle->HasCommitted(),
|
| + navigation_handle->IsSamePage(),
|
| + navigation_handle->HasCommitted() ? navigation_handle->GetPageTransition()
|
| + : -1,
|
| + navigation_handle->GetNetErrorCode());
|
| +}
|
| +
|
| void WebContentsObserverProxy::DidFinishLoad(RenderFrameHost* render_frame_host,
|
| const GURL& validated_url) {
|
| JNIEnv* env = AttachCurrentThread();
|
|
|