From 98c2c7100d1831ac0ed08ce5ef8e97026ea8242d Mon Sep 17 00:00:00 2001 From: Robert O'Callahan Date: Wed, 12 Mar 2014 09:11:37 +0800 Subject: [PATCH] Bug 917755. Part 1.5: Make nsImageLoadingContent more robust in unified builds. r=matspal --HG-- extra : rebase_source : be9acaac5b213666d02d1f6a95f132c46a7ada48 --- content/base/src/nsImageLoadingContent.cpp | 2 +- content/base/src/nsImageLoadingContent.h | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/content/base/src/nsImageLoadingContent.cpp b/content/base/src/nsImageLoadingContent.cpp index 64c7b0c8afd4..9548bc94e903 100644 --- a/content/base/src/nsImageLoadingContent.cpp +++ b/content/base/src/nsImageLoadingContent.cpp @@ -47,7 +47,7 @@ #include "mozilla/dom/Element.h" #include "mozilla/dom/ScriptSettings.h" -#if defined(XP_WIN) +#ifdef LoadImage // Undefine LoadImage to prevent naming conflict with Windows. #undef LoadImage #endif diff --git a/content/base/src/nsImageLoadingContent.h b/content/base/src/nsImageLoadingContent.h index 328124a757e6..7d5c5f3422fa 100644 --- a/content/base/src/nsImageLoadingContent.h +++ b/content/base/src/nsImageLoadingContent.h @@ -31,6 +31,11 @@ class nsPresContext; class nsIContent; class imgRequestProxy; +#ifdef LoadImage +// Undefine LoadImage to prevent naming conflict with Windows. +#undef LoadImage +#endif + class nsImageLoadingContent : public nsIImageLoadingContent, public imgIOnloadBlocker {