aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/effectmakernew/effectmakerview.h
blob: 2bed1cfc103bbd46630a9b267d2b30ca5077e901 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0

#pragma once

#include "abstractview.h"

#include <coreplugin/icontext.h>

#include <QPointer>

namespace EffectMaker {

class EffectMakerWidget;

class EffectMakerContext : public Core::IContext
{
    Q_OBJECT

public:
    EffectMakerContext(QWidget *widget);
    void contextHelp(const Core::IContext::HelpCallback &callback) const override;
};

class EffectMakerView : public QmlDesigner::AbstractView
{
public:
    EffectMakerView(QmlDesigner::ExternalDependenciesInterface &externalDependencies);
    ~EffectMakerView() override;

    bool hasWidget() const override;
    QmlDesigner::WidgetInfo widgetInfo() override;

    // AbstractView
    void modelAttached(QmlDesigner::Model *model) override;
    void modelAboutToBeDetached(QmlDesigner::Model *model) override;

private:
    void customNotification(const AbstractView *view, const QString &identifier,
                            const QList<QmlDesigner::ModelNode> &nodeList, const QList<QVariant> &data) override;

    QPointer<EffectMakerWidget> m_widget;
};

} // namespace EffectMaker