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

Side by Side Diff: content/browser/mojo/service_registry_android.cc

Issue 1552733002: Convert Pass()→std::move() in //content (Android edition) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 11 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/mojo/service_registry_android.h" 5 #include "content/browser/mojo/service_registry_android.h"
6 6
7 #include <utility>
8
7 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 10 #include "base/android/jni_string.h"
9 #include "base/callback.h" 11 #include "base/callback.h"
10 #include "content/common/mojo/service_registry_impl.h" 12 #include "content/common/mojo/service_registry_impl.h"
11 #include "jni/ServiceRegistry_jni.h" 13 #include "jni/ServiceRegistry_jni.h"
12 14
13 using base::android::AttachCurrentThread; 15 using base::android::AttachCurrentThread;
14 using base::android::ConvertJavaStringToUTF8; 16 using base::android::ConvertJavaStringToUTF8;
15 using base::android::ScopedJavaGlobalRef; 17 using base::android::ScopedJavaGlobalRef;
16 18
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 service_registry_->RemoveService(name); 89 service_registry_->RemoveService(name);
88 } 90 }
89 91
90 void ServiceRegistryAndroid::ConnectToRemoteService( 92 void ServiceRegistryAndroid::ConnectToRemoteService(
91 JNIEnv* env, 93 JNIEnv* env,
92 const JavaParamRef<jobject>& j_service_registry, 94 const JavaParamRef<jobject>& j_service_registry,
93 const JavaParamRef<jstring>& j_name, 95 const JavaParamRef<jstring>& j_name,
94 jint j_handle) { 96 jint j_handle) {
95 std::string name(ConvertJavaStringToUTF8(env, j_name)); 97 std::string name(ConvertJavaStringToUTF8(env, j_name));
96 mojo::ScopedMessagePipeHandle handle((mojo::MessagePipeHandle(j_handle))); 98 mojo::ScopedMessagePipeHandle handle((mojo::MessagePipeHandle(j_handle)));
97 service_registry_->ConnectToRemoteService(name, handle.Pass()); 99 service_registry_->ConnectToRemoteService(name, std::move(handle));
98 } 100 }
99 101
100 } // namespace content 102 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/media/android/media_session_uma_helper.cc ('k') | content/browser/renderer_host/compositor_impl_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698