#ifndef AUTOTEST_WIDGET_CONTAINER_H
#define AUTOTEST_WIDGET_CONTAINER_H

#include <QObject>
#include <QVector>

#include "widget-loader.h"

namespace UkuiQuick {

class Widget : public QObject
{
    Q_OBJECT
public:
    explicit Widget(const QString &id = QString(), QObject *parent = nullptr);

    QString id() const;

private:
    QString m_id;
};

class WidgetContainer : public Widget
{
    Q_OBJECT
public:
    explicit WidgetContainer(QObject *parent = nullptr);

    void addWidget(Widget *widget);
    void removeWidget(Widget *widget);
    QVector<Widget *> widgets() const;

Q_SIGNALS:
    void aboutToDeleted();

private:
    QVector<Widget *> m_widgets;
};

} // namespace UkuiQuick

#endif // AUTOTEST_WIDGET_CONTAINER_H
