summaryrefslogtreecommitdiff
path: root/vcl/unx/generic
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2021-11-30 09:04:00 +0100
committerLuboš Luňák <l.lunak@collabora.com>2021-11-30 11:18:35 +0100
commitcab4a0166a81749ba025be6e1ab39203bdee1e10 (patch)
treeff9cc59c081f7990995ab261ac4967dc1af0cfc4 /vcl/unx/generic
parent64ed0dcf6dbd9567ec33cd07ca8a15c63e86b9df (diff)
workaround gcc bug #55776 about enum class shadowing a global
GCC warns that 'enum class XorMode { None }' shadows 'constexpr int None = 0' for a workaround for X11 headers, even though there's no case for confusion here. So instead of a workaround for X11 headers work this around by placing the enum first, and then GCC does not complain. Change-Id: I3e7cfaced957d47dee8cc4f10ee74e8dd97a5cc5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126083 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'vcl/unx/generic')
-rw-r--r--vcl/unx/generic/app/salinst.cxx16
-rw-r--r--vcl/unx/generic/gdi/salgdi.cxx14
2 files changed, 15 insertions, 15 deletions
diff --git a/vcl/unx/generic/app/salinst.cxx b/vcl/unx/generic/app/salinst.cxx
index 54d20d2a8e7a..437614f35177 100644
--- a/vcl/unx/generic/app/salinst.cxx
+++ b/vcl/unx/generic/app/salinst.cxx
@@ -19,6 +19,14 @@
#include <stdlib.h>
+#include <config_features.h>
+#include <vcl/skia/SkiaHelper.hxx>
+#include <config_skia.h>
+#if HAVE_FEATURE_SKIA
+#include <skia/x11/gdiimpl.hxx>
+#include <skia/salbmp.hxx>
+#endif
+
#include <unx/saldata.hxx>
#include <unx/saldisp.hxx>
#include <unx/salinst.h>
@@ -33,14 +41,6 @@
#include <salwtype.hxx>
-#include <config_features.h>
-#include <vcl/skia/SkiaHelper.hxx>
-#include <config_skia.h>
-#if HAVE_FEATURE_SKIA
-#include <skia/x11/gdiimpl.hxx>
-#include <skia/salbmp.hxx>
-#endif
-
// plugin factory function
extern "C"
{
diff --git a/vcl/unx/generic/gdi/salgdi.cxx b/vcl/unx/generic/gdi/salgdi.cxx
index fd930bd10cfd..d65313843155 100644
--- a/vcl/unx/generic/gdi/salgdi.cxx
+++ b/vcl/unx/generic/gdi/salgdi.cxx
@@ -17,6 +17,13 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <config_features.h>
+#include <vcl/skia/SkiaHelper.hxx>
+#if HAVE_FEATURE_SKIA
+#include <skia/x11/gdiimpl.hxx>
+#include <skia/x11/textrender.hxx>
+#endif
+
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/extensions/Xrender.h>
@@ -50,13 +57,6 @@
#include "cairo_xlib_cairo.hxx"
#include <cairo-xlib.h>
-#include <config_features.h>
-#include <vcl/skia/SkiaHelper.hxx>
-#if HAVE_FEATURE_SKIA
-#include <skia/x11/gdiimpl.hxx>
-#include <skia/x11/textrender.hxx>
-#endif
-
X11SalGraphics::X11SalGraphics():
m_pFrame(nullptr),
m_pVDev(nullptr),