The documentation comment belongs to interface/wx/math.h, not the header
under include.
Also change the argument type to wxUint32 as the non-gcc version only
works for 32 bit values.
Generate wxJoystickEvent with the same fields under all platforms by
making the Linux and macOS versions follow MSW convention of using
"1 << N" for the changed button.
Add GetButtonOrdinal() accessor which can be used to retrieve just N.
Closes#18233.
std::isnan() is always available when using C++11, so just use it.
Also pout the test for C++11 implementations of both wxIsNaN() and wxFinite()
first, eventually the rest of the checks will become obsolete and will be
removed.
Closes https://github.com/wxWidgets/wxWidgets/pull/283
Windows CE doesn't seem to be supported by Microsoft any longer. Last CE
release was in early 2013 and the PocketPC and Smartphone targets supported by
wxWidgets are long gone.
The build files where already removed in an earlier cleanup this commit
removes all files, every #ifdef and all documentation regarding the Windows CE
support.
Closes https://github.com/wxWidgets/wxWidgets/pull/81
Declare _hypot() function globally, predefining __NO_INLINE__ in wx/math.h is
not enough as <math.h> is also included from some other standard headers, e.g.
<algorithm>, and including them results in the same bug as in wx/math.h
(i.e. https://sourceforge.net/p/mingw/bugs/2250/).
Including standard math.h header with both -O2 and -std=c++NN options results
in compilation error due to a bug in the header, see MinGW bug report at
https://sourceforge.net/p/mingw/bugs/2250/
Work around this to allow the library to compile in release build with
-std=c++11. This is ugly but better than failing to compile at all.
These options enable "strict ANSI" mode in MinGW which omits declarations of
POSIX functions from the standard headers. To allow the library and, possibly
even more importantly, the user code including our headers, to compile with
these options, declare the functions that we need ourselves.
This might appear to go against the spirit of "strict ANSI" mode, but the only
alternative would be to not use such functions at all and silently cripple the
library when -std=c++NN is used, compared to -std=g++NN case, and this doesn't
seem appealing neither.
Closes#16984.
This compiler is not being developed since several years and almost certainly
can't be used to build the current wxWidgets sources anyhow, so remove all
support for it, including a lot of extremely ugly workarounds for its bugs
with template functions.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76546 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This should fix compilation with MinGW 4.8.1 cross-compiler in C++11 mode as
it doesn't seem to provide finite() any more then.
Also, only defined wxFinite() and wxIsNaN() for C++, not C. This makes the
checks for __cplusplus >= 201103 simpler and is consistent with how
wxIsSameDouble() and wxRound() were already only defined for C++ (this is also
the source of most of the changes in this diff, viewing it ignoring whitespace
will show the only real changes).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74837 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This keyword is not expanded by Git which means it's not replaced with the
correct revision value in the releases made using git-based scripts and it's
confusing to have lines with unexpanded "$Id$" in the released files. As
expanding them with Git is not that simple (it could be done with git archive
and export-subst attribute) and there are not many benefits in having them in
the first place, just remove all these lines.
If nothing else, this will make an eventual transition to Git simpler.
Closes#14487.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74602 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Using the GNU libstdc++ or Clang's libc++ implementations of the
standard library, <cmath> inclusion undefines the isfinite macro,
resulting in compilation errors when wxFinite() is used. <cmath> can be
included unintentionally, e.g. wx/hashmap.h may result in its inclusion
when using STD containers.
Work around this mess by checking if one of these <cmath>
implementations were already included and using std::isfinite() in that
case.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74456 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Suppress the warnings about comparing floating point values for equality in
wxWidgets headers when the user code is compiled with -Wfloat-equal (at least
when using g++ 4.6 or later).
Closes#14895.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73280 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This compiler doesn't exist any more and was probably unsupported even in 2.8,
let alone 2.9, so remove all the __MWERKS__ tests to simplify things.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71102 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This change prepares the way for using wxGTK under Windows as this would
still define __WINDOWS__ but use __WXGTK__ instead of __WXMSW__.
Closes#14064.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70796 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Replaced C++ comments (occurring outside of __cplusplus blocks) in files that contain the warning "THIS IS A C FILE" with C comments.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67497 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775