#ifndef BLOCKWIDGET_H
#define BLOCKWIDGET_H

#include <QWidget>
#include <QPixmap>

class KLabel;
class QPushButton;
class QListView;
class LockDialogModel;

class BlockWidget  : public QWidget
{
    Q_OBJECT

public:
    explicit BlockWidget(LockDialogModel *model, QWidget *parent = nullptr);
    ~BlockWidget();
    void setTips(const QString tips);
    void setWarning(QStringList list, int type);
private:
    void initUi();

Q_SIGNALS:
    void cancelButtonclicked();
    void confirmButtonclicked();
private:
    KLabel          *m_tipLabel = nullptr;
    QListView       *m_listView = nullptr;
    QPushButton    *m_cancelButton = nullptr;
    QPushButton    *m_confirmButton = nullptr;
    LockDialogModel *m_modelLockDialog = nullptr;

    int             m_blockType = 0;
    bool            m_multiUsers = false;
    double          m_curFontSize;
    double          m_ptToPx = 1.0;
    QFont           sysFont;
};

#endif // BLOCKWIDGET_H
