diff options
Diffstat (limited to 'src-qt5/core/libLumina/LVideoLabel.h')
-rw-r--r-- | src-qt5/core/libLumina/LVideoLabel.h | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/src-qt5/core/libLumina/LVideoLabel.h b/src-qt5/core/libLumina/LVideoLabel.h new file mode 100644 index 00000000..56defb6a --- /dev/null +++ b/src-qt5/core/libLumina/LVideoLabel.h @@ -0,0 +1,42 @@ +#ifndef LVIDEOLABEL_H +#define LVIDEOLABEL_H + +#include <QLabel> +#include <QMediaPlayer> +#include <QTimer> +#include <QResizeEvent> +#include "LVideoSurface.h" + +class LVideoLabel : public QLabel{ + Q_OBJECT + public: + LVideoLabel(QString, bool, QWidget* parent=NULL); + ~LVideoLabel(); + void enableIcons(); + void disableIcons(); + + protected: + void enterEvent(QEvent*); + void leaveEvent(QEvent*); + void resizeEvent(QResizeEvent*); + + signals: + void rollOver(); + void frameReceived(QPixmap); + + private slots: + void initializeBackend(); + void stopVideo(QPixmap); + void setDuration(QMediaPlayer::MediaStatus); + void stateChanged(QMediaPlayer::State); + + private: + QMediaPlayer *mediaPlayer; + LVideoSurface *surface; + QPixmap thumbnail; + QPixmap defaultThumbnail; + bool entered; + bool icons; + QString filepath; +}; +#endif |