summaryrefslogtreecommitdiff
path: root/include/mupdf/fitz/document.h
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2015-04-16 09:50:15 +0100
committerTor Andersson <tor.andersson@artifex.com>2015-04-16 10:57:45 +0200
commit0fd24cefd86fb5bb627ee490d3f8127052516c5a (patch)
treed9aa4b290e41615b5c077ad34cea889fcf96267a /include/mupdf/fitz/document.h
parentdb9e364bb11233efb0c4420684972a6be389b837 (diff)
downloadmupdf-0fd24cefd86fb5bb627ee490d3f8127052516c5a.tar.xz
Avoid forward definition of enums.
ISO C++ dislikes forward definition of enums apparently. How crap is that?
Diffstat (limited to 'include/mupdf/fitz/document.h')
-rw-r--r--include/mupdf/fitz/document.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/include/mupdf/fitz/document.h b/include/mupdf/fitz/document.h
index 9e81efbb..c9b4f9cc 100644
--- a/include/mupdf/fitz/document.h
+++ b/include/mupdf/fitz/document.h
@@ -16,7 +16,15 @@ typedef struct fz_document_s fz_document;
typedef struct fz_document_handler_s fz_document_handler;
typedef struct fz_page_s fz_page;
typedef struct fz_annot_s fz_annot;
-typedef enum fz_permission_e fz_permission;
+
+typedef enum
+{
+ FZ_PERMISSION_PRINT = 'p',
+ FZ_PERMISSION_COPY = 'c',
+ FZ_PERMISSION_EDIT = 'e',
+ FZ_PERMISSION_ANNOTATE = 'n',
+}
+fz_permission;
// TODO: move out of this interface (it's pdf specific)
typedef struct fz_write_options_s fz_write_options;
@@ -308,14 +316,6 @@ fz_transition *fz_page_presentation(fz_context *ctx, fz_page *page, float *durat
*/
int fz_has_permission(fz_context *ctx, fz_document *doc, fz_permission p);
-enum fz_permission_e
-{
- FZ_PERMISSION_PRINT = 'p',
- FZ_PERMISSION_COPY = 'c',
- FZ_PERMISSION_EDIT = 'e',
- FZ_PERMISSION_ANNOTATE = 'n',
-};
-
/*
fz_lookup_metadata: Retrieve document meta data strings.