aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-07-31 18:52:31 +0000
committerGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-07-31 18:52:31 +0000
commitf3f2d1619e34deb6a1a8cf623f432927e09d0d3c (patch)
tree59931fbd121cf7fb79079efeb853f4036c32bfb2 /include
parentb6bd24d31f56622d3fb06eca2aa9ed0d8c52457b (diff)
set nominmax on windows
R=scroggo@google.com Review URL: https://codereview.chromium.org/20990007 git-svn-id: http://skia.googlecode.com/svn/trunk@10470 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r--include/core/SkPostConfig.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/core/SkPostConfig.h b/include/core/SkPostConfig.h
index 39d4eb73ab..022757554c 100644
--- a/include/core/SkPostConfig.h
+++ b/include/core/SkPostConfig.h
@@ -140,13 +140,23 @@
#define WIN32_LEAN_AND_MEAN
#define WIN32_IS_MEAN_WAS_LOCALLY_DEFINED
#endif
+ #ifndef NOMINMAX
+ #define NOMINMAX
+ #define NOMINMAX_WAS_LOCALLY_DEFINED
+ #endif
#include <windows.h>
#ifdef WIN32_IS_MEAN_WAS_LOCALLY_DEFINED
+ #undef WIN32_IS_MEAN_WAS_LOCALLY_DEFINED
#undef WIN32_LEAN_AND_MEAN
#endif
+ #ifdef NOMINMAX_WAS_LOCALLY_DEFINED
+ #undef NOMINMAX_WAS_LOCALLY_DEFINED
+ #undef NOMINMAX
+ #endif
+
#ifndef SK_DEBUGBREAK
#define SK_DEBUGBREAK(cond) do { if (!(cond)) { SkNO_RETURN_HINT(); __debugbreak(); }} while (false)
#endif