From: Vadim Zeitlin Date: Sun, 16 Jul 2006 20:15:55 +0000 (+0000) Subject: disable pixel size comparison in operator==() for wxGTK1 as it results in infinite... X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/82d0e7fe66384347c147ce58c6276c1033ebe04d disable pixel size comparison in operator==() for wxGTK1 as it results in infinite recursion there git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40138 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/fontcmn.cpp b/src/common/fontcmn.cpp index f111126f13..7c093918c5 100644 --- a/src/common/fontcmn.cpp +++ b/src/common/fontcmn.cpp @@ -328,7 +328,12 @@ bool wxFontBase::operator==(const wxFont& font) const ( Ok() == font.Ok() && GetPointSize() == font.GetPointSize() && + // in wxGTK1 GetPixelSize() calls GetInternalFont() which uses + // operator==() resulting in infinite recursion so we can't use it + // in that port +#if !defined(__WXGTK__) || defined(__WXGTK20__) GetPixelSize() == font.GetPixelSize() && +#endif GetFamily() == font.GetFamily() && GetStyle() == font.GetStyle() && GetWeight() == font.GetWeight() &&