OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 #include "SkTypes.h" | 7 #include "SkTypes.h" |
8 #if defined(SK_BUILD_FOR_WIN32) | 8 #if defined(SK_BUILD_FOR_WIN32) |
9 | 9 |
| 10 #include "SkLeanWindows.h" |
| 11 |
10 #include "gl/GrGLInterface.h" | 12 #include "gl/GrGLInterface.h" |
11 #include "gl/GrGLAssembleInterface.h" | 13 #include "gl/GrGLAssembleInterface.h" |
12 #include "gl/GrGLUtil.h" | 14 #include "gl/GrGLUtil.h" |
13 #define WIN32_LEAN_AND_MEAN | |
14 #include <windows.h> | |
15 | 15 |
16 class AutoLibraryUnload { | 16 class AutoLibraryUnload { |
17 public: | 17 public: |
18 AutoLibraryUnload(const char* moduleName) { | 18 AutoLibraryUnload(const char* moduleName) { |
19 fModule = LoadLibraryA(moduleName); | 19 fModule = LoadLibraryA(moduleName); |
20 } | 20 } |
21 ~AutoLibraryUnload() { | 21 ~AutoLibraryUnload() { |
22 if (fModule) { | 22 if (fModule) { |
23 FreeLibrary(fModule); | 23 FreeLibrary(fModule); |
24 } | 24 } |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 | 81 |
82 if (kGLES_GrGLStandard == standard) { | 82 if (kGLES_GrGLStandard == standard) { |
83 return GrGLAssembleGLESInterface(&getter, win_get_gl_proc); | 83 return GrGLAssembleGLESInterface(&getter, win_get_gl_proc); |
84 } else if (kGL_GrGLStandard == standard) { | 84 } else if (kGL_GrGLStandard == standard) { |
85 return GrGLAssembleGLInterface(&getter, win_get_gl_proc); | 85 return GrGLAssembleGLInterface(&getter, win_get_gl_proc); |
86 } | 86 } |
87 return nullptr; | 87 return nullptr; |
88 } | 88 } |
89 | 89 |
90 #endif//defined(SK_BUILD_FOR_WIN32) | 90 #endif//defined(SK_BUILD_FOR_WIN32) |
OLD | NEW |