Bug 1136494 - Try to pull <windows.h> include out of GLContext.h. - r=mtseng
authorJeff Gilbert <jgilbert@mozilla.com>
Thu, 14 Jul 2016 11:54:48 -0700
changeset 330430 3c35da4f57e67fb3571885b6ba5442009bf5f00d
parent 330429 0bf67462f9dc7603c70e21c65d01485694c7a2c3
child 330431 b78045c38ca2d18182e3cebe563e48e03a6c25e1
push id9858
push userjlund@mozilla.com
push dateMon, 01 Aug 2016 14:37:10 +0000
treeherdermozilla-aurora@203106ef6cb6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmtseng
bugs1136494
milestone50.0a1
Bug 1136494 - Try to pull <windows.h> include out of GLContext.h. - r=mtseng MozReview-Commit-ID: 7LwGBIxUqxU
gfx/gl/GLContext.h
gfx/gl/GLLibraryLoader.cpp
gfx/gl/GLLibraryLoader.h
--- a/gfx/gl/GLContext.h
+++ b/gfx/gl/GLContext.h
@@ -14,20 +14,16 @@
 #include <map>
 #include <queue>
 #include <stack>
 
 #ifdef DEBUG
 #include <string.h>
 #endif
 
-#ifdef WIN32
-#include <windows.h>
-#endif
-
 #ifdef GetClassName
 #undef GetClassName
 #endif
 
 // Define MOZ_GL_DEBUG unconditionally to enable GL debugging in opt
 // builds.
 #ifdef DEBUG
 #define MOZ_GL_DEBUG 1
@@ -37,17 +33,16 @@
 #include "../../mfbt/RefPtr.h"
 #include "../../mfbt/UniquePtr.h"
 
 #include "GLDefs.h"
 #include "GLLibraryLoader.h"
 #include "nsISupportsImpl.h"
 #include "plstr.h"
 #include "GLContextTypes.h"
-//#include "GLTextureImage.h"
 #include "SurfaceTypes.h"
 #include "GLContextSymbols.h"
 #include "base/platform_thread.h"       // for PlatformThreadId
 #include "mozilla/GenericRefCounted.h"
 #include "gfx2DGlue.h"
 #include "GeckoProfiler.h"
 
 class nsIWidget;
--- a/gfx/gl/GLLibraryLoader.cpp
+++ b/gfx/gl/GLLibraryLoader.cpp
@@ -1,16 +1,20 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "GLLibraryLoader.h"
 
 #include "nsDebug.h"
 
+#ifdef WIN32
+#include <windows.h>
+#endif
+
 namespace mozilla {
 namespace gl {
 
 bool
 GLLibraryLoader::OpenLibrary(const char* library)
 {
     PRLibSpec lspec;
     lspec.type = PR_LibSpec_Pathname;
--- a/gfx/gl/GLLibraryLoader.h
+++ b/gfx/gl/GLLibraryLoader.h
@@ -2,20 +2,16 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef GLLIBRARYLOADER_H_
 #define GLLIBRARYLOADER_H_
 
 #include <stdio.h>
 
-#ifdef WIN32
-#include <windows.h>
-#endif
-
 #include "GLDefs.h"
 #include "nscore.h"
 #include "prlink.h"
 
 namespace mozilla {
 namespace gl {
 
 class GLLibraryLoader