File indexing completed on 2025-03-09 03:52:10
0001 /* ============================================================ 0002 * 0003 * This file is a part of digiKam project 0004 * https://www.digikam.org 0005 * 0006 * Date : 2014-09-18 0007 * Description : slideshow OSD widget 0008 * 0009 * SPDX-FileCopyrightText: 2014-2024 by Gilles Caulier <caulier dot gilles at gmail dot com> 0010 * SPDX-FileCopyrightText: 2019-2020 by Minh Nghia Duong <minhnghiaduong997 at gmail dot com> 0011 * SPDX-FileCopyrightText: 2021 by Phuoc Khanh Le <phuockhanhnk94 at gmail dot com> 0012 * 0013 * SPDX-License-Identifier: GPL-2.0-or-later 0014 * 0015 * ============================================================ */ 0016 0017 #ifndef DIGIKAM_SLIDE_OSD_PLUGIN_H 0018 #define DIGIKAM_SLIDE_OSD_PLUGIN_H 0019 0020 // Qt includes 0021 0022 #include <QWidget> 0023 #include <QUrl> 0024 0025 // Local includes 0026 0027 #include "slideshowsettings.h" 0028 0029 class QEvent; 0030 0031 namespace DigikamGenericSlideShowPlugin 0032 { 0033 0034 class SlideShowLoader; 0035 class SlideToolBar; 0036 0037 class SlideOSD : public QWidget 0038 { 0039 Q_OBJECT 0040 0041 public: 0042 0043 explicit SlideOSD(SlideShowSettings* const settings, SlideShowLoader* const parent); 0044 ~SlideOSD() override; 0045 0046 void setCurrentUrl(const QUrl& url); 0047 0048 void pause(bool b); 0049 void video(bool b); 0050 bool isPaused() const; 0051 bool isUnderMouse() const; 0052 void setLoadingReady(bool b); 0053 0054 0055 SlideToolBar* toolBar() const; 0056 QSize slideShowSize() const; 0057 0058 private Q_SLOTS: 0059 0060 void slotUpdateSettings(); 0061 void slotProgressTimer(); 0062 void slotStart(); 0063 0064 private: 0065 0066 bool eventFilter(QObject* obj, QEvent* ev) override; 0067 0068 private: 0069 0070 class Private; 0071 Private* const d; 0072 }; 0073 0074 } // namespace DigikamGenericSlideShowPlugin 0075 0076 #endif // DIGIKAM_SLIDE_OSD_PLUGIN_H