summaryrefslogtreecommitdiff
path: root/public/fpdf_attachment.h
diff options
context:
space:
mode:
authorHenrique Nakashima <hnakashima@chromium.org>2017-08-10 15:13:19 +0000
committerChromium commit bot <commit-bot@chromium.org>2017-08-10 15:13:33 +0000
commit7e805d1a6f3bf7ddd04b2c1ce857a2cf6d9ff873 (patch)
tree0aab30fc879ea390d3f3351dafc5511e16ddedc0 /public/fpdf_attachment.h
parente6c67cd64a80bd67c587ad3ffb380fe1b7574d1f (diff)
downloadpdfium-7e805d1a6f3bf7ddd04b2c1ce857a2cf6d9ff873.tar.xz
Revert "Add a build target and a proper export header for shared library builds."
This reverts commit 00334675c18a0203f313cceb670c970a77280f49. Reason for revert: Breaking the deps roller - https://chromium-review.googlesource.com/c/609307 Original change's description: > Add a build target and a proper export header for shared library builds. > > This CL adds support for Chromium's component build feature to pdfium. > > The export header stub in fpdfview.h is expanded to match Chromium's > export mechanisms and patterns (fixes pdfium:825). > > A component/shared library build can be triggered by adding > > is_component_build = true > > as a gn argument. Please note that setting this will also affect some > of pdfiums dependencies like v8, which will be build as components > too. > > Additionally, this CL provides a "pdf_source_set" template which > dynamically enables the use of "source_set" when building a complete > static library or a shared library to reduce build time. > > When testing this it is recommended to only build the pdfium target as > most of pdfiums test rely on non-public functions which aren't exported > by the shared library. > > Bug: pdfium:825,pdfium:826 > Change-Id: Icedc538ec535e11d1e53c4d5fabc8c064b275752 > Reviewed-on: https://pdfium-review.googlesource.com/8970 > Reviewed-by: dsinclair <dsinclair@chromium.org> > Commit-Queue: dsinclair <dsinclair@chromium.org> TBR=thestig@chromium.org,tsepez@chromium.org,brucedawson@chromium.org,dsinclair@google.com,dsinclair@chromium.org,licorn@gmail.com Change-Id: Ib02af2298932481293f50d362ae87bfedf284821 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: pdfium:825, pdfium:826 Reviewed-on: https://pdfium-review.googlesource.com/10550 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Diffstat (limited to 'public/fpdf_attachment.h')
-rw-r--r--public/fpdf_attachment.h38
1 files changed, 18 insertions, 20 deletions
diff --git a/public/fpdf_attachment.h b/public/fpdf_attachment.h
index 5a7ab6a722..a5a84658a2 100644
--- a/public/fpdf_attachment.h
+++ b/public/fpdf_attachment.h
@@ -18,8 +18,7 @@ extern "C" {
// document - handle to a document.
//
// Returns the number of embedded files in |document|.
-FPDF_EXPORT int FPDF_CALLCONV
-FPDFDoc_GetAttachmentCount(FPDF_DOCUMENT document);
+DLLEXPORT int STDCALL FPDFDoc_GetAttachmentCount(FPDF_DOCUMENT document);
// Experimental API.
// Add an embedded file with |name| in |document|. If |name| is empty, or if
@@ -31,8 +30,8 @@ FPDFDoc_GetAttachmentCount(FPDF_DOCUMENT document);
// name - name of the new attachment.
//
// Returns a handle to the new attachment object, or NULL on failure.
-FPDF_EXPORT FPDF_ATTACHMENT FPDF_CALLCONV
-FPDFDoc_AddAttachment(FPDF_DOCUMENT document, FPDF_WIDESTRING name);
+DLLEXPORT FPDF_ATTACHMENT STDCALL FPDFDoc_AddAttachment(FPDF_DOCUMENT document,
+ FPDF_WIDESTRING name);
// Experimental API.
// Get the embedded attachment at |index| in |document|. Note that the returned
@@ -42,8 +41,8 @@ FPDFDoc_AddAttachment(FPDF_DOCUMENT document, FPDF_WIDESTRING name);
// index - the index of the requested embedded file.
//
// Returns the handle to the attachment object, or NULL on failure.
-FPDF_EXPORT FPDF_ATTACHMENT FPDF_CALLCONV
-FPDFDoc_GetAttachment(FPDF_DOCUMENT document, int index);
+DLLEXPORT FPDF_ATTACHMENT STDCALL FPDFDoc_GetAttachment(FPDF_DOCUMENT document,
+ int index);
// Experimental API.
// Delete the embedded attachment at |index| in |document|. Note that this does
@@ -55,8 +54,8 @@ FPDFDoc_GetAttachment(FPDF_DOCUMENT document, int index);
// index - the index of the embedded file to be deleted.
//
// Returns true if successful.
-FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV
-FPDFDoc_DeleteAttachment(FPDF_DOCUMENT document, int index);
+DLLEXPORT FPDF_BOOL STDCALL FPDFDoc_DeleteAttachment(FPDF_DOCUMENT document,
+ int index);
// Experimental API.
// Get the name of the |attachment| file. |buffer| is only modified if |buflen|
@@ -68,7 +67,7 @@ FPDFDoc_DeleteAttachment(FPDF_DOCUMENT document, int index);
// buflen - length of the buffer.
//
// Returns the length of the file name.
-FPDF_EXPORT unsigned long FPDF_CALLCONV
+DLLEXPORT unsigned long STDCALL
FPDFAttachment_GetName(FPDF_ATTACHMENT attachment,
void* buffer,
unsigned long buflen);
@@ -80,8 +79,8 @@ FPDFAttachment_GetName(FPDF_ATTACHMENT attachment,
// key - the key to look for.
//
// Returns true if |key| exists.
-FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV
-FPDFAttachment_HasKey(FPDF_ATTACHMENT attachment, FPDF_WIDESTRING key);
+DLLEXPORT FPDF_BOOL STDCALL FPDFAttachment_HasKey(FPDF_ATTACHMENT attachment,
+ FPDF_WIDESTRING key);
// Experimental API.
// Get the type of the value corresponding to |key| in the params dictionary of
@@ -91,7 +90,7 @@ FPDFAttachment_HasKey(FPDF_ATTACHMENT attachment, FPDF_WIDESTRING key);
// key - the key to look for.
//
// Returns the type of the dictionary value.
-FPDF_EXPORT FPDF_OBJECT_TYPE FPDF_CALLCONV
+DLLEXPORT FPDF_OBJECT_TYPE STDCALL
FPDFAttachment_GetValueType(FPDF_ATTACHMENT attachment, FPDF_WIDESTRING key);
// Experimental API.
@@ -104,7 +103,7 @@ FPDFAttachment_GetValueType(FPDF_ATTACHMENT attachment, FPDF_WIDESTRING key);
// value - the string value to be set, encoded in UTF16-LE.
//
// Returns true if successful.
-FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV
+DLLEXPORT FPDF_BOOL STDCALL
FPDFAttachment_SetStringValue(FPDF_ATTACHMENT attachment,
FPDF_WIDESTRING key,
FPDF_WIDESTRING value);
@@ -125,7 +124,7 @@ FPDFAttachment_SetStringValue(FPDF_ATTACHMENT attachment,
// buflen - length of the buffer.
//
// Returns the length of the dictionary value string.
-FPDF_EXPORT unsigned long FPDF_CALLCONV
+DLLEXPORT unsigned long STDCALL
FPDFAttachment_GetStringValue(FPDF_ATTACHMENT attachment,
FPDF_WIDESTRING key,
void* buffer,
@@ -142,11 +141,10 @@ FPDFAttachment_GetStringValue(FPDF_ATTACHMENT attachment,
// len - length of file data.
//
// Returns true if successful.
-FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV
-FPDFAttachment_SetFile(FPDF_ATTACHMENT attachment,
- FPDF_DOCUMENT document,
- const void* contents,
- const unsigned long len);
+DLLEXPORT FPDF_BOOL STDCALL FPDFAttachment_SetFile(FPDF_ATTACHMENT attachment,
+ FPDF_DOCUMENT document,
+ const void* contents,
+ const unsigned long len);
// Experimental API.
// Get the file data of |attachment|. |buffer| is only modified if |buflen| is
@@ -158,7 +156,7 @@ FPDFAttachment_SetFile(FPDF_ATTACHMENT attachment,
// buflen - length of the buffer.
//
// Returns the length of the file.
-FPDF_EXPORT unsigned long FPDF_CALLCONV
+DLLEXPORT unsigned long STDCALL
FPDFAttachment_GetFile(FPDF_ATTACHMENT attachment,
void* buffer,
unsigned long buflen);