halcanary | 4dbbd04 | 2016-06-07 17:21:10 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 Google Inc. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license that can be |
| 5 | * found in the LICENSE file. |
| 6 | */ |
| 7 | #ifndef SkLeanWindows_DEFINED |
| 8 | #define SkLeanWindows_DEFINED |
| 9 | |
| 10 | #include "SkTypes.h" |
| 11 | |
| 12 | #ifdef SK_BUILD_FOR_WIN |
| 13 | # ifndef WIN32_LEAN_AND_MEAN |
| 14 | # define WIN32_LEAN_AND_MEAN |
| 15 | # define WIN32_IS_MEAN_WAS_LOCALLY_DEFINED |
| 16 | # endif |
| 17 | # ifndef NOMINMAX |
| 18 | # define NOMINMAX |
| 19 | # define NOMINMAX_WAS_LOCALLY_DEFINED |
| 20 | # endif |
| 21 | # |
| 22 | # include <windows.h> |
| 23 | # |
| 24 | # ifdef WIN32_IS_MEAN_WAS_LOCALLY_DEFINED |
| 25 | # undef WIN32_IS_MEAN_WAS_LOCALLY_DEFINED |
| 26 | # undef WIN32_LEAN_AND_MEAN |
| 27 | # endif |
| 28 | # ifdef NOMINMAX_WAS_LOCALLY_DEFINED |
| 29 | # undef NOMINMAX_WAS_LOCALLY_DEFINED |
| 30 | # undef NOMINMAX |
| 31 | # endif |
| 32 | #endif |
| 33 | |
| 34 | #endif // SkLeanWindows_DEFINED |