[Libreoffice-commits] core.git: vcl/win

Stephan Bergmann sbergman at redhat.com
Wed Apr 17 05:54:56 PDT 2013


 vcl/win/source/gdi/salgdi_gdiplus.cxx |    9 +++++++++
 1 file changed, 9 insertions(+)

New commits:
commit 7828f4377033f8dcceb8ff9368b6d613a1dd7b2b
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Wed Apr 17 14:54:06 2013 +0200

    MSC needs those min/max macros after all
    
    ...otherwise, it will fail with "c:\program files\microsoft
    sdks\windows\v7.1\include\GdiplusTypes.h(470) : error C3861: 'min': identifier
    not found" errors.
    
    Change-Id: Ib81ab7f5357b1f980202b63b144296fa252b71b1

diff --git a/vcl/win/source/gdi/salgdi_gdiplus.cxx b/vcl/win/source/gdi/salgdi_gdiplus.cxx
index f26ccaa..d1b9d0a 100644
--- a/vcl/win/source/gdi/salgdi_gdiplus.cxx
+++ b/vcl/win/source/gdi/salgdi_gdiplus.cxx
@@ -27,6 +27,15 @@
 #include <win/salgdi.h>
 
 #if defined _MSC_VER
+#ifndef min
+#define min(a,b)    (((a) < (b)) ? (a) : (b))
+#endif
+#ifndef max
+#define max(a,b)    (((a) > (b)) ? (a) : (b))
+#endif
+#endif
+
+#if defined _MSC_VER
 #pragma warning(push, 1)
 #endif
 


More information about the Libreoffice-commits mailing list