#ifndef MASKWIDGET_H
#define MASKWIDGET_H

#include <QDialog>

namespace Ui {
class MaskWidget;
}

class MaskWidget : public QDialog
{
    Q_OBJECT
    Q_PROPERTY(QStringList names READ names WRITE setNames DESIGNABLE true)

public:
    static MaskWidget *instance();

    void setMainWidget(QWidget* pWidget);

    QStringList names() const;
    void setNames(const QStringList& names);

protected:
    bool eventFilter(QObject *obj, QEvent *event);

private:
    Ui::MaskWidget *ui;

    explicit MaskWidget(QWidget *parent = nullptr);
    ~MaskWidget();

    static MaskWidget * m_pSelf;

    QStringList m_listName{ QStringList() };
    QWidget* m_pMainWidget{ Q_NULLPTR };
};

#endif // MASKWIDGET_H
