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

Side by Side Diff: content/browser/web_contents/web_contents_android.cc

Issue 372693003: [Android] Fix smart clip callback to include URI and title (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: really removed mSmartClipResultHandler Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/browser/web_contents/web_contents_android.h" 5 #include "content/browser/web_contents/web_contents_android.h"
6 6
7 #include "base/android/jni_android.h" 7 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 8 #include "base/android/jni_string.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "content/public/browser/browser_thread.h" 10 #include "content/public/browser/browser_thread.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 WebContentsAndroid::GetJavaObject() { 55 WebContentsAndroid::GetJavaObject() {
56 return base::android::ScopedJavaLocalRef<jobject>(obj_); 56 return base::android::ScopedJavaLocalRef<jobject>(obj_);
57 } 57 }
58 58
59 ScopedJavaLocalRef<jstring> WebContentsAndroid::GetTitle( 59 ScopedJavaLocalRef<jstring> WebContentsAndroid::GetTitle(
60 JNIEnv* env, jobject obj) const { 60 JNIEnv* env, jobject obj) const {
61 return base::android::ConvertUTF16ToJavaString(env, 61 return base::android::ConvertUTF16ToJavaString(env,
62 web_contents_->GetTitle()); 62 web_contents_->GetTitle());
63 } 63 }
64 64
65 ScopedJavaLocalRef<jstring> WebContentsAndroid::GetVisibleURL(
66 JNIEnv* env, jobject obj) const {
67 return base::android::ConvertUTF8ToJavaString(
68 env, web_contents_->GetVisibleURL().spec());
69 }
70
65 void WebContentsAndroid::Stop(JNIEnv* env, jobject obj) { 71 void WebContentsAndroid::Stop(JNIEnv* env, jobject obj) {
66 web_contents_->Stop(); 72 web_contents_->Stop();
67 } 73 }
68 74
69 } // namespace content 75 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698