From eeb69ba18558107bdfcdde32ed8be349f24698e4 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 7 Jul 2020 15:31:26 +0200 Subject: [PATCH] Fix wxGLCanvas build in wxQt when using MSVC Use "#pragma message" instead of "#warning" with this compiler to fix the build after the recent changes of 589e043358 (Add an explicit warning about missing OpenGL support in wxQt, 2020-07-06). --- src/qt/glcanvas.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/qt/glcanvas.cpp b/src/qt/glcanvas.cpp index 4cd442504c..0bd3cc8931 100644 --- a/src/qt/glcanvas.cpp +++ b/src/qt/glcanvas.cpp @@ -14,7 +14,13 @@ #include -#warning "OpenGL support is not implemented in wxQt" +#if defined(__VISUALC__) + #pragma message("OpenGL support is not implemented in wxQt") +#elif defined(__BORLANDC__) + #pragma message "OpenGL support is not implemented in wxQt" +#else + #warning "OpenGL support is not implemented in wxQt" +#endif wxGCC_WARNING_SUPPRESS(unused-parameter) class wxQtGLWidget : public wxQtEventSignalHandler< QGLWidget, wxGLCanvas >