avmedia/IwyuFilter_avmedia.yaml | 12 +++---- avmedia/source/framework/MediaControlBase.cxx | 1 avmedia/source/framework/mediaitem.cxx | 1 avmedia/source/framework/soundhandler.cxx | 2 - avmedia/source/framework/soundhandler.hxx | 3 - avmedia/source/gstreamer/gstcommon.hxx | 43 -------------------------- avmedia/source/gstreamer/gstframegrabber.cxx | 5 --- avmedia/source/gstreamer/gstframegrabber.hxx | 4 +- avmedia/source/gstreamer/gstmanager.cxx | 2 + avmedia/source/gstreamer/gstmanager.hxx | 2 - avmedia/source/gstreamer/gstplayer.cxx | 2 - avmedia/source/gstreamer/gstplayer.hxx | 5 ++- avmedia/source/gstreamer/gstwindow.cxx | 2 - avmedia/source/gstreamer/gstwindow.hxx | 1 avmedia/source/gtk/gtkmanager.cxx | 2 + avmedia/source/gtk/gtkmanager.hxx | 1 avmedia/source/gtk/gtkplayer.cxx | 6 --- avmedia/source/gtk/gtkplayer.hxx | 2 - avmedia/source/inc/mediamisc.hxx | 2 - avmedia/source/qt6/QtFrameGrabber.cxx | 1 avmedia/source/qt6/QtPlayer.cxx | 6 --- avmedia/source/viewer/mediaevent_impl.cxx | 1 avmedia/source/viewer/mediawindow.cxx | 3 - avmedia/source/viewer/mediawindow_impl.cxx | 1 24 files changed, 19 insertions(+), 91 deletions(-)
New commits: commit 1e6a99f3263cdc2617b0f5bd7e97dd72ecdada22 Author: Gabor Kelemen <gabor.kele...@collabora.com> AuthorDate: Sun Jul 13 22:51:46 2025 +0200 Commit: Gabor Kelemen <gabor.kelemen.ext...@allotropia.de> CommitDate: Wed Jul 30 12:44:32 2025 +0200 tdf#146619 Run IWYU on avmedia/ - kill gstcommon.hxx - check 'new' modules gtk4 and qt6 - recheck everything else Change-Id: I7e4a9f308d49c0aa948d6278231aab24e797c799 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187832 Reviewed-by: Gabor Kelemen <gabor.kelemen.ext...@allotropia.de> Tested-by: Jenkins diff --git a/avmedia/IwyuFilter_avmedia.yaml b/avmedia/IwyuFilter_avmedia.yaml index c370c1ed00b1..551e6c7255df 100644 --- a/avmedia/IwyuFilter_avmedia.yaml +++ b/avmedia/IwyuFilter_avmedia.yaml @@ -1,9 +1,9 @@ --- assumeFilename: avmedia/source/gstreamer/gstplayer.cxx excludelist: - avmedia/source/viewer/mediawindow_impl.cxx: - # Actually used - - com/sun/star/uno/XComponentContext.hpp - avmedia/source/viewer/mediawindow.cxx: - # Actually used - - com/sun/star/media/XPlayer.hpp + avmedia/source/gstreamer/gstframegrabber.hxx: + # Keep catch-all main gstreamer header + - gst/gst.h + avmedia/source/gstreamer/gstplayer.hxx: + # Keep catch-all main gstreamer header + - gst/gst.h diff --git a/avmedia/source/framework/MediaControlBase.cxx b/avmedia/source/framework/MediaControlBase.cxx index 9d09e925372c..1f4261c00566 100644 --- a/avmedia/source/framework/MediaControlBase.cxx +++ b/avmedia/source/framework/MediaControlBase.cxx @@ -19,7 +19,6 @@ #include <avmedia/MediaControlBase.hxx> #include <avmedia/mediaplayer.hxx> #include <avmedia/mediaitem.hxx> -#include <tools/time.hxx> #include <tools/duration.hxx> #include <unotools/localedatawrapper.hxx> #include <strings.hrc> diff --git a/avmedia/source/framework/mediaitem.cxx b/avmedia/source/framework/mediaitem.cxx index fbabb684383e..cb8cdd3fb22f 100644 --- a/avmedia/source/framework/mediaitem.cxx +++ b/avmedia/source/framework/mediaitem.cxx @@ -39,7 +39,6 @@ #include <comphelper/mediamimetype.hxx> #include <comphelper/processfactory.hxx> #include <comphelper/storagehelper.hxx> -#include <mediamisc.hxx> #include <osl/file.hxx> #include <comphelper/diagnose_ex.hxx> #include <vcl/graph.hxx> diff --git a/avmedia/source/framework/soundhandler.cxx b/avmedia/source/framework/soundhandler.cxx index 5af9aca90594..6b9045cc5efd 100644 --- a/avmedia/source/framework/soundhandler.cxx +++ b/avmedia/source/framework/soundhandler.cxx @@ -25,8 +25,6 @@ #include <com/sun/star/frame/DispatchResultState.hpp> #include <avmedia/mediawindow.hxx> -#include <cppuhelper/queryinterface.hxx> -#include <cppuhelper/typeprovider.hxx> #include <cppuhelper/factory.hxx> #include <cppuhelper/supportsservice.hxx> diff --git a/avmedia/source/framework/soundhandler.hxx b/avmedia/source/framework/soundhandler.hxx index a143fcb87eaa..7b93888573d1 100644 --- a/avmedia/source/framework/soundhandler.hxx +++ b/avmedia/source/framework/soundhandler.hxx @@ -19,7 +19,6 @@ #pragma once -#include <com/sun/star/lang/XTypeProvider.hpp> #include <com/sun/star/frame/XNotifyingDispatch.hpp> #include <com/sun/star/frame/XStatusListener.hpp> #include <com/sun/star/document/XExtendedFilterDetection.hpp> @@ -30,8 +29,6 @@ #include <com/sun/star/lang/XServiceInfo.hpp> #include <comphelper/compbase.hxx> -#include <cppuhelper/basemutex.hxx> -#include <cppuhelper/weak.hxx> #include <vcl/timer.hxx> #include <vcl/idle.hxx> diff --git a/avmedia/source/gstreamer/gstcommon.hxx b/avmedia/source/gstreamer/gstcommon.hxx deleted file mode 100644 index 0e27907fb312..000000000000 --- a/avmedia/source/gstreamer/gstcommon.hxx +++ /dev/null @@ -1,43 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#pragma once - -#include <gst/gst.h> - -#include <osl/mutex.hxx> -#include <tools/stream.hxx> -#include <tools/urlobj.hxx> -#include <cppuhelper/weak.hxx> -#include <cppuhelper/factory.hxx> - -#include <com/sun/star/uno/Reference.h> -#include <com/sun/star/uno/RuntimeException.hpp> -#include <com/sun/star/lang/XMultiServiceFactory.hpp> -#include <com/sun/star/lang/XComponent.hpp> -#include <com/sun/star/registry/XRegistryKey.hpp> -#include <com/sun/star/lang/XServiceInfo.hpp> -#include <com/sun/star/awt/Rectangle.hpp> -#include <com/sun/star/awt/KeyModifier.hpp> -#include <com/sun/star/awt/MouseButton.hpp> -#include <com/sun/star/media/XManager.hpp> - -#define WM_GRAPHNOTIFY (WM_USER + 567) - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/avmedia/source/gstreamer/gstframegrabber.cxx b/avmedia/source/gstreamer/gstframegrabber.cxx index d8f96bd5e568..1fd437e4aa0c 100644 --- a/avmedia/source/gstreamer/gstframegrabber.cxx +++ b/avmedia/source/gstreamer/gstframegrabber.cxx @@ -18,19 +18,14 @@ */ #include "gstframegrabber.hxx" -#include "gstplayer.hxx" #include <cppuhelper/supportsservice.hxx> #include <gst/gstbuffer.h> -#include <gst/video/video.h> -#include <gst/video/gstvideosink.h> #include <o3tl/safeint.hxx> #include <vcl/graph.hxx> #include <vcl/BitmapTools.hxx> -#include <string> - constexpr OUString AVMEDIA_GST_FRAMEGRABBER_SERVICENAME = u"com.sun.star.media.FrameGrabber_GStreamer"_ustr; using namespace ::com::sun::star; diff --git a/avmedia/source/gstreamer/gstframegrabber.hxx b/avmedia/source/gstreamer/gstframegrabber.hxx index c706192efd7d..a040573bc724 100644 --- a/avmedia/source/gstreamer/gstframegrabber.hxx +++ b/avmedia/source/gstreamer/gstframegrabber.hxx @@ -21,9 +21,11 @@ #include <sal/config.h> +#include <gst/gst.h> + #include <string_view> -#include "gstplayer.hxx" +#include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XFrameGrabber.hpp> #include <cppuhelper/implbase.hxx> #include <rtl/ref.hxx> diff --git a/avmedia/source/gstreamer/gstmanager.cxx b/avmedia/source/gstreamer/gstmanager.cxx index addbccd231bf..fb3e797a2abc 100644 --- a/avmedia/source/gstreamer/gstmanager.cxx +++ b/avmedia/source/gstreamer/gstmanager.cxx @@ -22,6 +22,8 @@ #include "gstmanager.hxx" #include "gstplayer.hxx" +#include <com/sun/star/uno/XComponentContext.hpp> + #include <tools/urlobj.hxx> #include <rtl/ref.hxx> diff --git a/avmedia/source/gstreamer/gstmanager.hxx b/avmedia/source/gstreamer/gstmanager.hxx index 21a5245dd933..ccc195d733cf 100644 --- a/avmedia/source/gstreamer/gstmanager.hxx +++ b/avmedia/source/gstreamer/gstmanager.hxx @@ -19,8 +19,8 @@ #pragma once -#include "gstcommon.hxx" #include <cppuhelper/implbase.hxx> +#include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XManager.hpp> namespace avmedia::gstreamer { diff --git a/avmedia/source/gstreamer/gstplayer.cxx b/avmedia/source/gstreamer/gstplayer.cxx index 65371ec547ea..602435db5f83 100644 --- a/avmedia/source/gstreamer/gstplayer.cxx +++ b/avmedia/source/gstreamer/gstplayer.cxx @@ -21,8 +21,6 @@ #include <algorithm> #include <cassert> -#include <chrono> -#include <cstddef> #include <cstring> #include <map> #include <mutex> diff --git a/avmedia/source/gstreamer/gstplayer.hxx b/avmedia/source/gstreamer/gstplayer.hxx index 2694ac00ce7e..371facfa8d58 100644 --- a/avmedia/source/gstreamer/gstplayer.hxx +++ b/avmedia/source/gstreamer/gstplayer.hxx @@ -21,11 +21,14 @@ #include <sal/config.h> +#include <gst/gst.h> + #include <string_view> #include <osl/conditn.hxx> -#include "gstcommon.hxx" +#include <tools/long.hxx> +#include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XPlayer.hpp> #include <cppuhelper/compbase.hxx> #include <cppuhelper/basemutex.hxx> diff --git a/avmedia/source/gstreamer/gstwindow.cxx b/avmedia/source/gstreamer/gstwindow.cxx index 2d9aec0418b3..5606b310b4f8 100644 --- a/avmedia/source/gstreamer/gstwindow.cxx +++ b/avmedia/source/gstreamer/gstwindow.cxx @@ -17,8 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include <com/sun/star/awt/SystemPointer.hpp> - #include <cppuhelper/supportsservice.hxx> #include "gstwindow.hxx" diff --git a/avmedia/source/gstreamer/gstwindow.hxx b/avmedia/source/gstreamer/gstwindow.hxx index 68a94867b820..9750d7335972 100644 --- a/avmedia/source/gstreamer/gstwindow.hxx +++ b/avmedia/source/gstreamer/gstwindow.hxx @@ -20,7 +20,6 @@ #pragma once #include <cppuhelper/implbase.hxx> -#include <cppuhelper/interfacecontainer.h> #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XPlayerWindow.hpp> diff --git a/avmedia/source/gtk/gtkmanager.cxx b/avmedia/source/gtk/gtkmanager.cxx index fe823c1f49ed..311f61bf5837 100644 --- a/avmedia/source/gtk/gtkmanager.cxx +++ b/avmedia/source/gtk/gtkmanager.cxx @@ -9,6 +9,8 @@ #include <cppuhelper/supportsservice.hxx> +#include <com/sun/star/uno/XComponentContext.hpp> + #include "gtkmanager.hxx" #include "gtkplayer.hxx" diff --git a/avmedia/source/gtk/gtkmanager.hxx b/avmedia/source/gtk/gtkmanager.hxx index 9cf6d93f5b68..cfc224ee2f94 100644 --- a/avmedia/source/gtk/gtkmanager.hxx +++ b/avmedia/source/gtk/gtkmanager.hxx @@ -12,7 +12,6 @@ #include <cppuhelper/implbase.hxx> #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XManager.hpp> -#include <com/sun/star/uno/XComponentContext.hpp> namespace avmedia::gtk { diff --git a/avmedia/source/gtk/gtkplayer.cxx b/avmedia/source/gtk/gtkplayer.cxx index 8ade48191174..b3b572e42aab 100644 --- a/avmedia/source/gtk/gtkplayer.cxx +++ b/avmedia/source/gtk/gtkplayer.cxx @@ -9,18 +9,12 @@ #include <sal/config.h> -#include <mutex> - #include <cppuhelper/supportsservice.hxx> -#include <sal/log.hxx> #include <rtl/string.hxx> -#include <tools/link.hxx> #include <vcl/BitmapTools.hxx> #include <vcl/graph.hxx> -#include <vcl/svapp.hxx> #include <vcl/syschild.hxx> #include <vcl/sysdata.hxx> -#include <vcl/timer.hxx> #include <gstwindow.hxx> #include "gtkplayer.hxx" diff --git a/avmedia/source/gtk/gtkplayer.hxx b/avmedia/source/gtk/gtkplayer.hxx index 46e416e79e25..a67ee48c5982 100644 --- a/avmedia/source/gtk/gtkplayer.hxx +++ b/avmedia/source/gtk/gtkplayer.hxx @@ -11,8 +11,6 @@ #include <sal/config.h> -#include <string_view> - #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/media/XPlayer.hpp> #include <com/sun/star/media/XPlayerNotifier.hpp> diff --git a/avmedia/source/inc/mediamisc.hxx b/avmedia/source/inc/mediamisc.hxx index 53983aa27370..b0b7cdd59ade 100644 --- a/avmedia/source/inc/mediamisc.hxx +++ b/avmedia/source/inc/mediamisc.hxx @@ -19,8 +19,6 @@ #pragma once -#include <comphelper/mediamimetype.hxx> - #include <unotools/resmgr.hxx> #ifdef _WIN32 diff --git a/avmedia/source/qt6/QtFrameGrabber.cxx b/avmedia/source/qt6/QtFrameGrabber.cxx index 44886286e48c..3e62a69d5f26 100644 --- a/avmedia/source/qt6/QtFrameGrabber.cxx +++ b/avmedia/source/qt6/QtFrameGrabber.cxx @@ -13,7 +13,6 @@ #include <sal/log.hxx> #include <vcl/filter/PngImageReader.hxx> #include <vcl/graph.hxx> -#include <vcl/image.hxx> #include <vcl/qt/QtUtils.hxx> #include <vcl/scheduler.hxx> diff --git a/avmedia/source/qt6/QtPlayer.cxx b/avmedia/source/qt6/QtPlayer.cxx index d3576807b887..b14d8cd3a52a 100644 --- a/avmedia/source/qt6/QtPlayer.cxx +++ b/avmedia/source/qt6/QtPlayer.cxx @@ -22,15 +22,9 @@ #include <comphelper/processfactory.hxx> #include <cppuhelper/supportsservice.hxx> #include <sal/log.hxx> -#include <rtl/string.hxx> -#include <tools/link.hxx> -#include <vcl/BitmapTools.hxx> -#include <vcl/graph.hxx> #include <vcl/qt/QtUtils.hxx> -#include <vcl/svapp.hxx> #include <vcl/syschild.hxx> #include <vcl/sysdata.hxx> -#include <vcl/timer.hxx> #include <gstwindow.hxx> #include <mediamisc.hxx> diff --git a/avmedia/source/viewer/mediaevent_impl.cxx b/avmedia/source/viewer/mediaevent_impl.cxx index d6a2c082c246..5c7f95e33d11 100644 --- a/avmedia/source/viewer/mediaevent_impl.cxx +++ b/avmedia/source/viewer/mediaevent_impl.cxx @@ -18,7 +18,6 @@ */ #include "mediaevent_impl.hxx" -#include <osl/mutex.hxx> #include <vcl/svapp.hxx> #include <vcl/event.hxx> #include <vcl/window.hxx> diff --git a/avmedia/source/viewer/mediawindow.cxx b/avmedia/source/viewer/mediawindow.cxx index 0750414b06b2..a4eb12c35720 100644 --- a/avmedia/source/viewer/mediawindow.cxx +++ b/avmedia/source/viewer/mediawindow.cxx @@ -28,8 +28,7 @@ #include <vcl/svapp.hxx> #include <vcl/weld.hxx> #include <sfx2/filedlghelper.hxx> -#include <com/sun/star/awt/Size.hpp> -#include <com/sun/star/frame/XDispatchHelper.hpp> +#include <com/sun/star/frame/XDispatchProvider.hpp> #include <com/sun/star/media/XPlayer.hpp> #include <com/sun/star/media/XPlayerNotifier.hpp> #include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp> diff --git a/avmedia/source/viewer/mediawindow_impl.cxx b/avmedia/source/viewer/mediawindow_impl.cxx index 513c6b89fb30..c1b0f1c6721d 100644 --- a/avmedia/source/viewer/mediawindow_impl.cxx +++ b/avmedia/source/viewer/mediawindow_impl.cxx @@ -25,7 +25,6 @@ #include <helpids.h> #include <algorithm> -#include <string_view> #include <sal/log.hxx> #include <comphelper/processfactory.hxx>