#ifndef WIDGET_H
#define WIDGET_H

#include <QWidget>
#include <memory>
#include <QTimer>
#include <qwidget.h>

#include "IVideoPlayer.h"
#include "VideoPlayerAPI.h"

QT_BEGIN_NAMESPACE
namespace Ui { class Widget; }
QT_END_NAMESPACE

class Widget : public QWidget
{
    Q_OBJECT

public:
    Widget(QWidget *parent = nullptr);
    ~Widget();


public slots:
    void on_pBtn_openFile_clicked();

    void on_pBtn_play_clicked();

    void on_pBtn_playNetwork_clicked();

private slots:

protected:
    void resizeEvent(QResizeEvent *event) override;
    
private:
    Ui::Widget *ui;

    QWidget* m_playerWidget = nullptr;  // 播放器的显示窗口
    IVideoPlayer *m_player = nullptr;   

    QTimer m_timer;

};
#endif // WIDGET_H
