summaryrefslogtreecommitdiff
path: root/include/defs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/defs.h')
-rw-r--r--include/defs.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/include/defs.h b/include/defs.h
index fd1ebf5..fdad3db 100644
--- a/include/defs.h
+++ b/include/defs.h
@@ -2,7 +2,7 @@
*
* defs.h - Global defines, mostly platform-specific stuff
*
- * $Id: defs.h 2942 2013-08-03 08:39:02Z chrislit $
+ * $Id: defs.h 3156 2014-04-17 03:50:37Z greg.hellings $
*
* Copyright 2000-2013 CrossWire Bible Society (http://www.crosswire.org)
* CrossWire Bible Society
@@ -25,12 +25,18 @@
#ifndef SWORDDEFS_H
#define SWORDDEFS_H
+// TODO: What is this? jansorg, why does NO_SWORD_NAMESPACE still define
+// a C++ namespace, and then force using it? This makes no sense to me.
+// see commit 1195
#ifdef NO_SWORD_NAMESPACE
#define SWORD_NAMESPACE_START namespace sword {
#define SWORD_NAMESPACE_END }; using namespace sword;
-#else
+#elif defined(__cplusplus)
#define SWORD_NAMESPACE_START namespace sword {
#define SWORD_NAMESPACE_END }
+#else
+ #define SWORD_NAMESPACE_START
+ #define SWORD_NAMESPACE_END
#endif
SWORD_NAMESPACE_START
@@ -154,10 +160,12 @@ SWORD_NAMESPACE_START
+#ifdef __cplusplus
enum {DIRECTION_LTR = 0, DIRECTION_RTL, DIRECTION_BIDI};
enum {FMT_UNKNOWN = 0, FMT_PLAIN, FMT_THML, FMT_GBF, FMT_HTML, FMT_HTMLHREF, FMT_RTF, FMT_OSIS, FMT_WEBIF, FMT_TEI, FMT_XHTML};
enum {ENC_UNKNOWN = 0, ENC_LATIN1, ENC_UTF8, ENC_SCSU, ENC_UTF16, ENC_RTF, ENC_HTML};
enum {BIB_BIBTEX = 0, /* possible future formats: BIB_MARCXML, BIB_MARC21, BIB_DCMI BIB_OSISHEADER, BIB_SBL_XHTML, BIB_MLA_XHTML, BIB_APA_XHTML, BIB_CHICAGO_XHTML */};
+#endif
SWORD_NAMESPACE_END
#endif //SWORDDEFS_H