-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathActionWindowInterfaceBase.h
More file actions
55 lines (39 loc) · 1.94 KB
/
ActionWindowInterfaceBase.h
File metadata and controls
55 lines (39 loc) · 1.94 KB
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
47
48
49
50
51
52
53
54
55
#ifndef DIFFSCOPE_COREPLUGIN_ACTIONWINDOWINTERFACEBASE_H
#define DIFFSCOPE_COREPLUGIN_ACTIONWINDOWINTERFACEBASE_H
#include <qqmlintegration.h>
#include <CoreApi/windowinterface.h>
#include <SVSCraftCore/SVSCraftNamespace.h>
#include <coreplugin/coreglobal.h>
namespace QAK {
class QuickActionContext;
}
class QAbstractItemModel;
class QJSValue;
class QQuickMenu;
namespace Core {
class ActionWindowInterfaceBasePrivate;
class CORE_EXPORT ActionWindowInterfaceBase : public WindowInterface {
Q_OBJECT
QML_ELEMENT
QML_UNCREATABLE("")
Q_PROPERTY(QAK::QuickActionContext *actionContext READ actionContext CONSTANT)
Q_PROPERTY(QWidget *invisibleCentralWidget READ invisibleCentralWidget CONSTANT)
Q_DECLARE_PRIVATE(ActionWindowInterfaceBase)
public:
QAK::QuickActionContext *actionContext() const;
QWidget *invisibleCentralWidget() const;
Q_INVOKABLE bool triggerAction(const QString &id, QObject *source = nullptr);
Q_INVOKABLE int execQuickPick(QAbstractItemModel *model, const QString &placeholderText = {}, int defaultIndex = 0, const QString &initialFilterText = {});
Q_INVOKABLE void execQuickPick(QQuickMenu *menu);
Q_INVOKABLE QVariant execQuickInput(const QString &placeholderText = {}, const QString &promptText = {}, const QString &initialText = {});
Q_INVOKABLE QVariant execQuickInput(const QString &placeholderText, const QString &promptText, const QString &initialText, const QJSValue &callback);
protected:
explicit ActionWindowInterfaceBase(QObject *parent = nullptr);
explicit ActionWindowInterfaceBase(ActionWindowInterfaceBasePrivate &d, QObject *parent = nullptr);
~ActionWindowInterfaceBase() override;
void nextLoadingState(State nextState) override;
private:
QScopedPointer<ActionWindowInterfaceBasePrivate> d_ptr;
};
}
#endif //DIFFSCOPE_COREPLUGIN_ACTIONWINDOWINTERFACEBASE_H