#define va_list __gnuc_va_list
#endif /* HP-UX */
+/* Prevents conflicts between sys/types.h and winsock.h with Cygwin, */
+/* when using Windows sockets. */
+#ifdef __CYGWIN__
+#define __USE_W32_SOCKETS
+#endif
+
/* ---------------------------------------------------------------------------- */
/* check for native bool type and TRUE/FALSE constants */
/* ---------------------------------------------------------------------------- */
#error "SIZEOF_WCHAR_T must be defined, but isn't"
#endif
-#if !defined(wxSIZE_T_IS_UINT) && !defined(wxSIZE_T_IS_ULONG)
- #error "wxSIZE_T_IS_UINT or wxSIZE_T_IS_ULONG must be defined"
-#endif
-
/* also define C99-like sized MIN/MAX constants */
#define wxINT8_MIN CHAR_MIN
#define wxINT8_MAX CHAR_MAX
#define wxULongLong_t unsigned wxLongLong_t
#endif
- /* these macros allow to define 64 bit constants in a portable way */
- #define wxLL(x) wxCONCAT(x, wxLongLongSuffix)
- #define wxULL(x) wxCONCAT(x, wxCONCAT(u, wxLongLongSuffix))
+ /*
+ wxLL() and wxULL() macros allow to define 64 bit constants in a
+ portable way.
+ */
+ #ifndef wxCOMPILER_BROKEN_CONCAT_OPER
+ #define wxLL(x) wxCONCAT(x, wxLongLongSuffix)
+ #define wxULL(x) wxCONCAT(x, wxCONCAT(u, wxLongLongSuffix))
+ #else
+ // Currently only Borland compiler has broken concatenation operator
+ // and this compiler is known to use [u]i64 suffix.
+ #define wxLL(x) wxAPPEND_i64(x)
+ #define wxULL(x) wxAPPEND_ui64(x)
+ #endif
typedef wxLongLong_t wxInt64;
typedef wxULongLong_t wxUint64;
#define wxHAS_INT64 1
+ #ifndef wxLongLongIsLong
+ #define wxHAS_LONG_LONG_T_DIFFERENT_FROM_LONG
+ #endif
#elif wxUSE_LONGLONG
/* these macros allow to define 64 bit constants in a portable way */
#define wxLL(x) wxLongLong(x)
#endif
#endif
+/* ---------------------------------------------------------------------------- */
+/* template workarounds for buggy compilers */
+/* ---------------------------------------------------------------------------- */
+
+#if defined(__GNUC__) && !wxCHECK_GCC_VERSION( 3, 4 )
+ // GCC <= 3.4 has buggy template support
+# define wxUSE_MEMBER_TEMPLATES 0
+#endif
+
+#if defined(_MSC_VER) && _MSC_VER <= 1200
+ // MSVC <= 6.0 has buggy template support
+# define wxUSE_MEMBER_TEMPLATES 0
+# define wxUSE_FUNC_TEMPLATE_POINTER 0
+#endif
+
+#ifndef wxUSE_MEMBER_TEMPLATES
+# define wxUSE_MEMBER_TEMPLATES 1
+#endif
+
+#ifndef wxUSE_FUNC_TEMPLATE_POINTER
+# define wxUSE_FUNC_TEMPLATE_POINTER 1
+#endif
+
+#if wxUSE_MEMBER_TEMPLATES
+# define wxTEMPLATED_MEMBER_CALL( method, type ) method<type>()
+# define wxTEMPLATED_MEMBER_FIX( type )
+#else
+# define wxTEMPLATED_MEMBER_CALL( method, type ) method((type*)NULL)
+# define wxTEMPLATED_MEMBER_FIX( type ) type* =NULL
+#endif
+
+#if defined(_MSC_VER) && _MSC_VER <= 1200
+# define wxTEMPLATED_FUNCTION_FIX( type ), wxTEMPLATED_MEMBER_FIX(type)
+# define wxINFUNC_CLASS_TYPE_FIX( type ) typedef type type;
+#else
+# define wxTEMPLATED_FUNCTION_FIX( type )
+# define wxINFUNC_CLASS_TYPE_FIX( type )
+#endif
+
/* ---------------------------------------------------------------------------- */
/* Geometric flags */
/* ---------------------------------------------------------------------------- */
/*
* wxSpinButton flags.
- * Note that a wxSpinCtrl is sometimes defined as
- * a wxTextCtrl, and so the flags must be different
- * from wxTextCtrl's.
+ * Note that a wxSpinCtrl is sometimes defined as a wxTextCtrl, and so the
+ * flags shouldn't overlap with wxTextCtrl flags that can be used for a single
+ * line controls (currently we reuse wxTE_CHARWRAP and wxTE_RICH2 neither of
+ * which makes sense for them).
*/
#define wxSP_HORIZONTAL wxHORIZONTAL /* 4 */
#define wxSP_VERTICAL wxVERTICAL /* 8 */
-#define wxSP_ARROW_KEYS 0x1000
-#define wxSP_WRAP 0x2000
+#define wxSP_ARROW_KEYS 0x4000
+#define wxSP_WRAP 0x8000
/*
* wxTabCtrl flags
wxID_MDI_WINDOW_NEXT,
wxID_MDI_WINDOW_LAST = wxID_MDI_WINDOW_NEXT,
+ /* OS X system menu ids */
+ wxID_OSX_MENU_FIRST = 5250,
+ wxID_OSX_HIDE = wxID_OSX_MENU_FIRST,
+ wxID_OSX_HIDEOTHERS,
+ wxID_OSX_SHOWALL,
+ wxID_OSX_MENU_LAST = wxID_OSX_SHOWALL,
+
/* IDs used by generic file dialog (13 consecutive starting from this value) */
wxID_FILEDLGG = 5900,
wxDF_MAX
};
-/* Virtual keycodes */
+/* Key codes */
enum wxKeyCode
{
+ WXK_NONE = 0,
+
WXK_BACK = 8, // backspace
WXK_TAB = 9,
WXK_RETURN = 13,