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

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

Issue 12527012: Add PPAPI C++ wrappers for PDF. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ppapi/cpp/private/pdf.cc » ('j') | ppapi/cpp/private/pdf.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/cpp/private/pdf.h
diff --git a/ppapi/cpp/private/pdf.h b/ppapi/cpp/private/pdf.h
new file mode 100644
index 0000000000000000000000000000000000000000..d688e016a0f1c1aa4f586acff0c6c64b108948e2
--- /dev/null
+++ b/ppapi/cpp/private/pdf.h
@@ -0,0 +1,62 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef PPAPI_CPP_PRIVATE_PDF_H_
+#define PPAPI_CPP_PRIVATE_PDF_H_
+
+#include <string>
+
+#include "ppapi/c/private/ppb_pdf.h"
+
+namespace pp {
+
+class ImageData;
+class InstanceHandle;
+class Var;
+
+class PDF {
+ public:
+ // Returns true if the required interface is available.
+ static bool IsAvailable();
+
+ static Var GetLocalizedString(const InstanceHandle& instance,
+ PP_ResourceString string_id);
+ static pp::ImageData GetResourceImage(const InstanceHandle& instance,
yzshen1 2013/03/18 17:55:47 you don't need pp::
raymes 2013/03/18 18:15:39 Done.
+ PP_ResourceImage image_id);
+ static PP_Resource GetFontFileWithFallback(
+ const InstanceHandle& instance,
+ const struct PP_FontDescription_Dev* description,
yzshen1 2013/03/18 17:55:47 you don't need 'struct'. nit, question: I don't k
raymes 2013/03/18 18:15:39 Done. I'm not sure - probably a reference is more
yzshen1 2013/03/18 19:25:14 I don't think it is very important. Thanks! On 201
+ PP_PrivateFontCharset charset);
+ static bool GetFontTableForPrivateFontFile(const InstanceHandle& instance,
+ PP_Resource font_file,
+ uint32_t table,
+ void* output,
+ uint32_t* output_length);
+ static void SearchString(const InstanceHandle& instance,
+ const unsigned short* string,
+ const unsigned short* term,
+ bool case_sensitive,
+ struct PP_PrivateFindResult** results,
yzshen1 2013/03/18 17:55:47 you don't need 'struct'.
raymes 2013/03/18 18:15:39 Done.
+ int* count);
+ static void DidStartLoading(const InstanceHandle& instance);
+ static void DidStopLoading(const InstanceHandle& instance);
+ static void SetContentRestriction(const InstanceHandle& instance,
+ int restrictions);
+ static void HistogramPDFPageCount(const InstanceHandle& instance,
+ int count);
+ static void UserMetricsRecordAction(const InstanceHandle& instance,
+ const Var& action);
+ static void HasUnsupportedFeature(const InstanceHandle& instance);
+ static void SaveAs(const InstanceHandle& instance);
+ static void Print(const InstanceHandle& instance);
+ static bool IsFeatureEnabled(const InstanceHandle& instance,
+ PP_PDFFeature feature);
+ static pp::ImageData GetResourceImageForScale(const InstanceHandle& instance,
yzshen1 2013/03/18 17:55:47 you don't need pp::
raymes 2013/03/18 18:15:39 Done.
+ PP_ResourceImage image_id,
+ float scale);
+};
+
+} // namespace pp
+
+#endif // PPAPI_CPP_PRIVATE_PDF_H_
« no previous file with comments | « no previous file | ppapi/cpp/private/pdf.cc » ('j') | ppapi/cpp/private/pdf.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698