summaryrefslogtreecommitdiff
path: root/vcl/inc/qt5
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2022-06-18 21:11:28 +0200
committerMichael Weghorn <m.weghorn@posteo.de>2022-06-19 02:09:29 +0200
commite4d23c27288b99c3ed3cfa332ff308b31c01f97d (patch)
treebeb1c69fc807b72a798790d12405ae6c403fbba7 /vcl/inc/qt5
parent455197df7f7520bcce8c3f4210dfbb12ae0e7e60 (diff)
qt: Fix qt6 build after fbc61e06584ff8e6d9240f8b67be8dc28ecab5b9
Failed like this: In file included from /home/michi/development/git/libreoffice/vcl/qt6/QtX11Support.cxx:10: /home/michi/development/git/libreoffice/vcl/qt6/../qt5/QtX11Support.cxx:15:10: fatal error: QtX11Extras/QX11Info: No such file or directory 15 | #include <QtX11Extras/QX11Info> | ^~~~~~~~~~~~~~~~~~~~~~ compilation terminated. make[1]: *** [/home/michi/development/git/libreoffice/solenv/gbuild/LinkTarget.mk:334: /home/michi/development/git/libreoffice/workdir/CxxObject/vcl/qt6/QtX11Support.o] Error 1 make[1]: *** Waiting for unfinished jobs.... In file included from /home/michi/development/git/libreoffice/vcl/qt6/QtFrame.cxx:10: /home/michi/development/git/libreoffice/vcl/qt6/../qt5/QtFrame.cxx: In member function ‘virtual void QtFrame::StartPresentation(bool)’: /home/michi/development/git/libreoffice/vcl/qt6/../qt5/QtFrame.cxx:746:5: error: ‘m_ScreenSaverInhibitor’ was not declared in this scope 746 | m_ScreenSaverInhibitor.inhibit(bStart, u"presentation", bIsX11, aRootWindow, aDisplay); | ^~~~~~~~~~~~~~~~~~~~~~ make[1]: *** [/home/michi/development/git/libreoffice/solenv/gbuild/LinkTarget.mk:334: /home/michi/development/git/libreoffice/workdir/CxxObject/vcl/qt6/QtFrame.o] Error 1 make: *** [Makefile:288: build] Error 2 As mentioned in [1], `QX11Info` has been removed in Qt 6. The `ScreenSaverInhibitor` related code (except for the `QX11Info` part) can be used for Qt 6 as well, so adapt the checks in the header accordingly. [1] https://www.qt.io/blog/qt-extras-modules-in-qt-6 Co-authored-by: Jan-Marek Glogowski <glogow@fbihome.de> Change-Id: Ifd546b4f4210aaf7f09ebaa8c36d2a031763d492 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136091 Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'vcl/inc/qt5')
-rw-r--r--vcl/inc/qt5/QtFrame.hxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/vcl/inc/qt5/QtFrame.hxx b/vcl/inc/qt5/QtFrame.hxx
index 562c7d3ba89a..963572ca819b 100644
--- a/vcl/inc/qt5/QtFrame.hxx
+++ b/vcl/inc/qt5/QtFrame.hxx
@@ -33,7 +33,7 @@
#include <QtCore/QObject>
-#if CHECK_QT5_USING_X11
+#if CHECK_ANY_QT_USING_X11
#include <unx/screensaverinhibitor.hxx>
// any better way to get rid of the X11 / Qt type clashes?
#undef Bool
@@ -101,10 +101,8 @@ class VCLPLUG_QT_PUBLIC QtFrame : public QObject, public SalFrame
sal_uInt32 m_nRestoreScreen;
QRect m_aRestoreGeometry;
-#if CHECK_QT5_USING_X11
- ScreenSaverInhibitor m_ScreenSaverInhibitor;
-#endif
#if CHECK_ANY_QT_USING_X11
+ ScreenSaverInhibitor m_ScreenSaverInhibitor;
ModKeyFlags m_nKeyModifiers;
#endif