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

Unified Diff: ppapi/cpp/private/pdf.cc

Issue 705623002: Initialize V8 in PDFium from external files (in-renderer process only). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments from Ross and Raymes Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« ppapi/cpp/private/pdf.h ('K') | « ppapi/cpp/private/pdf.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/cpp/private/pdf.cc
diff --git a/ppapi/cpp/private/pdf.cc b/ppapi/cpp/private/pdf.cc
index ac5b941fad4f920394c3d8f476ec056d532804fc..a32d4be07c14be59d1b2303fe2bf09550133a591 100644
--- a/ppapi/cpp/private/pdf.cc
+++ b/ppapi/cpp/private/pdf.cc
@@ -197,4 +197,24 @@ void PDF::SetLinkUnderCursor(const InstanceHandle& instance, const char* url) {
get_interface<PPB_PDF>()->SetLinkUnderCursor(instance.pp_instance(), url);
}
+#ifdef V8_USE_EXTERNAL_STARTUP_DATA
raymes 2014/11/10 03:29:06 same here
baixo1 2014/11/10 15:59:49 Done.
+// static
+void PDF::GetV8ExternalSnapshotData(const InstanceHandle& instance,
+ const char** natives_data_out,
+ int* natives_size_out,
+ const char** snapshot_data_out,
+ int* snapshot_size_out) {
+ if (has_interface<PPB_PDF>()) {
+ get_interface<PPB_PDF>()->GetV8ExternalSnapshotData(instance.pp_instance(),
+ natives_data_out,
+ natives_size_out,
+ snapshot_data_out,
+ snapshot_size_out);
+ return;
+ }
+ *natives_data_out = *snapshot_data_out = NULL;
+ *natives_size_out = *snapshot_size_out = 0;
raymes 2014/11/10 03:29:07 nit: same here please break up this line
baixo1 2014/11/10 15:59:49 Done.
+}
+#endif
+
} // namespace pp
« ppapi/cpp/private/pdf.h ('K') | « ppapi/cpp/private/pdf.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698