mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Avoid copying vector in mounting layer of Fabric
Summary: easy diff to avoid the constant copy of a vector when calling the method Binding.createRemoveAndDeleteMultiMountItem. Since we are not modifing the vector inside the method createRemoveAndDeleteMultiMountItem it's not necessary to copy it. Changelog: Improve performance in mounting of Fabric views Reviewed By: JoshuaGross Differential Revision: D18250376 fbshipit-source-id: c984214a8148bab521cec51d42ba54a4b73e3e67
This commit is contained in:
committed by
Facebook Github Bot
parent
2afc4e2482
commit
00266693b3
@@ -475,7 +475,7 @@ local_ref<JMountItem::javaobject> createDeleteMountItem(
|
||||
|
||||
local_ref<JMountItem::javaobject> createRemoveAndDeleteMultiMountItem(
|
||||
const jni::global_ref<jobject> &javaUIManager,
|
||||
std::vector<RemoveDeleteMetadata> metadata) {
|
||||
const std::vector<RemoveDeleteMetadata> &metadata) {
|
||||
|
||||
auto env = Environment::current();
|
||||
auto removeAndDeleteArray = env->NewIntArray(metadata.size()*4);
|
||||
|
||||
Reference in New Issue
Block a user