Skip to content
Extraits de code Groupes Projets
Sélectionner une révision Git
  • ef653527fb6ea751ae7f66c203cd352d6bd6ecba
  • master par défaut protégée
  • rust-playlist-sync
  • rust
  • fix-qt-deprecated-qvariant-type
  • fix-mpris-qtwindow-race-condition
  • rust-appimage-wayland
  • windows-build-rebased
  • v2.5 protégée
  • v2.4 protégée
  • v2.3-1 protégée
  • v2.3 protégée
  • v2.2 protégée
  • v2.1 protégée
  • v2.0 protégée
  • v1.8-3 protégée
  • v1.8-2 protégée
  • v1.8-1 protégée
  • v1.8 protégée
  • v1.7 protégée
  • v1.6 protégée
  • v1.5 protégée
  • v1.4 protégée
  • v1.3 protégée
  • v1.2 protégée
  • v1.1 protégée
  • v1.0 protégée
27 résultats

mpvwidget.hh

Blame
  • mpvwidget.hh 1,01 Kio
    #ifndef __LKT_MODULE_QT_WINDOW__
    #define __LKT_MODULE_QT_WINDOW__
    
    #include <QtWidgets/QOpenGLWidget>
    #include <mpv/client.h>
    #include <mpv/render_gl.h>
    #include <QtGui>
    
    #include <lektor/common.h>
    
    class MpvWidget Q_DECL_FINAL: public QOpenGLWidget
    {
        Q_OBJECT
    public:
        MpvWidget(struct queue *queue, lkt_db *db);
        ~MpvWidget();
        void command(const QVariant& params);
        void setProperty(const QString& name, const QVariant& value);
        QVariant getProperty(const QString& name) const;
        QSize sizeHint() const { return QSize(480, 270);}
    Q_SIGNALS:
        void durationChanged(int value);
        void positionChanged(int value);
    protected:
        void initializeGL() Q_DECL_OVERRIDE;
        void paintGL() Q_DECL_OVERRIDE;
    private Q_SLOTS:
        void on_mpv_events();
        void maybeUpdate();
    public:
        void handle_mpv_event(mpv_event *event);
        static void on_update(void *ctx);
    
        mpv_handle *mpv;
        mpv_render_context *mpv_gl;
    
    private:
        struct queue *m_queue;
        lkt_db *m_db;
    };
    
    #endif // __LKT_MODULE_QT_WINDOW__