File indexing completed on 2024-05-05 04:22:01
0001 // SPDX-FileCopyrightText: 2012-2022 Jesper K. Pedersen <blackie@kde.org> 0002 // 0003 // SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL 0004 0005 #ifndef VIDEOLENGTHEXTRACTOR_H 0006 #define VIDEOLENGTHEXTRACTOR_H 0007 0008 #include <kpabase/FileName.h> 0009 0010 #include <QObject> 0011 0012 namespace Utilities 0013 { 0014 class Process; 0015 } 0016 0017 namespace ImageManager 0018 { 0019 0020 /** 0021 \brief \todo 0022 \see \ref videothumbnails 0023 */ 0024 class VideoLengthExtractor : public QObject 0025 { 0026 Q_OBJECT 0027 public: 0028 explicit VideoLengthExtractor(QObject *parent = nullptr); 0029 void extract(const DB::FileName &fileName); 0030 0031 Q_SIGNALS: 0032 void lengthFound(int length); 0033 void unableToDetermineLength(); 0034 0035 private Q_SLOTS: 0036 void processEnded(); 0037 0038 private: 0039 Utilities::Process *m_process; 0040 DB::FileName m_fileName; 0041 }; 0042 0043 } 0044 0045 #endif // VIDEOLENGTHEXTRACTOR_H 0046 // vi:expandtab:tabstop=4 shiftwidth=4: