Improve performance of plugin/mimehandler messaging
When converting PP_PrivateAccessibilityLink/ImageInfo to PdfAccessibilityLink/ImageInfo, we used to first store it in a variable and then emplace_back it. This caused the struct to be created twice. Instead, we directly pass the C struct to emplace_back and it will automatically call the appropriate constructor to create the C++ object in place. This way, the C++ object is only created once. Bug: 981448 Change-Id: I1da00c47ac7dbab7057389d6850bcfcffa433cd5 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1778596 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by:Bill Budge <bbudge@chromium.org> Reviewed-by:
Lei Zhang <thestig@chromium.org> Reviewed-by:
Ian Prest <iapres@microsoft.com> Cr-Commit-Position: refs/heads/master@{#696867}
Showing
Please register or sign in to comment