X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bfa29337d4b4a998b2197b1c40f1837ddc3eba11..7d605004a217d4f4ef674d7edf073982d8931995:/include/wx/defs.h?ds=sidebyside diff --git a/include/wx/defs.h b/include/wx/defs.h index d9aad8ce61..7d67449000 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -639,6 +639,15 @@ typedef short int WXTYPE; ptr = NULL; } } + + // trivial implementation of std::swap() for primitive types + template + inline void wxSwap(T& first, T& second) + { + T tmp(first); + first = second; + second = tmp; + } #endif /*__cplusplus*/ /* size of statically declared array */ @@ -1866,8 +1875,10 @@ enum wxBorder #define wxAPPLY 0x00000020 #define wxCLOSE 0x00000040 -#define wxYES_DEFAULT 0x00000000 /* has no effect (default) */ -#define wxNO_DEFAULT 0x00000080 +#define wxOK_DEFAULT 0x00000000 /* has no effect (default) */ +#define wxYES_DEFAULT 0x00000000 /* has no effect (default) */ +#define wxNO_DEFAULT 0x00000080 /* only valid with wxYES_NO */ +#define wxCANCEL_DEFAULT 0x80000000 /* only valid with wxCANCEL */ #define wxICON_EXCLAMATION 0x00000100 #define wxICON_HAND 0x00000200