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

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

Issue 2801003004: Add "Paste as plain text" into text selection toolbar overflow (Closed)
Patch Set: check more styles Created 3 years, 8 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 <stdint.h> 7 #include <stdint.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 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 } 335 }
336 336
337 void WebContentsAndroid::Copy(JNIEnv* env, const JavaParamRef<jobject>& obj) { 337 void WebContentsAndroid::Copy(JNIEnv* env, const JavaParamRef<jobject>& obj) {
338 web_contents_->Copy(); 338 web_contents_->Copy();
339 } 339 }
340 340
341 void WebContentsAndroid::Paste(JNIEnv* env, const JavaParamRef<jobject>& obj) { 341 void WebContentsAndroid::Paste(JNIEnv* env, const JavaParamRef<jobject>& obj) {
342 web_contents_->Paste(); 342 web_contents_->Paste();
343 } 343 }
344 344
345 void WebContentsAndroid::PasteAsPlainText(JNIEnv* env,
346 const JavaParamRef<jobject>& obj) {
347 web_contents_->PasteAndMatchStyle();
348 }
349
345 void WebContentsAndroid::Replace(JNIEnv* env, 350 void WebContentsAndroid::Replace(JNIEnv* env,
346 const JavaParamRef<jobject>& obj, 351 const JavaParamRef<jobject>& obj,
347 const JavaParamRef<jstring>& jstr) { 352 const JavaParamRef<jstring>& jstr) {
348 web_contents_->Replace(base::android::ConvertJavaStringToUTF16(env, jstr)); 353 web_contents_->Replace(base::android::ConvertJavaStringToUTF16(env, jstr));
349 } 354 }
350 355
351 void WebContentsAndroid::SelectAll(JNIEnv* env, 356 void WebContentsAndroid::SelectAll(JNIEnv* env,
352 const JavaParamRef<jobject>& obj) { 357 const JavaParamRef<jobject>& obj) {
353 web_contents_->SelectAll(); 358 web_contents_->SelectAll();
354 } 359 }
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after
783 env, obj, callback, id, http_status_code, jurl, jbitmaps, jsizes); 788 env, obj, callback, id, http_status_code, jurl, jbitmaps, jsizes);
784 } 789 }
785 790
786 void WebContentsAndroid::SetMediaSession( 791 void WebContentsAndroid::SetMediaSession(
787 const ScopedJavaLocalRef<jobject>& j_media_session) { 792 const ScopedJavaLocalRef<jobject>& j_media_session) {
788 JNIEnv* env = base::android::AttachCurrentThread(); 793 JNIEnv* env = base::android::AttachCurrentThread();
789 Java_WebContentsImpl_setMediaSession(env, obj_, j_media_session); 794 Java_WebContentsImpl_setMediaSession(env, obj_, j_media_session);
790 } 795 }
791 796
792 } // namespace content 797 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698