OSSIA
Open Scenario System for Interactive Application
Loading...
Searching...
No Matches
qml_loop.hpp
1#pragma once
2#include <ossia/editor/loop/loop.hpp>
3
4#include <ossia-qt/score/qml_autom.hpp>
5#include <ossia-qt/score/qml_cond.hpp>
6#include <ossia-qt/score/qml_interval.hpp>
7#include <ossia-qt/score/qml_sync.hpp>
8
9#include <verdigris>
10
11namespace ossia
12{
13namespace qt
14{
15class qml_loop : public qml_process
16{
17 W_OBJECT(qml_loop)
18
19public:
20 qml_loop(QQuickItem* parent = nullptr);
21 ~qml_loop() override;
22
23 qml_interval* interval() const;
24 void setup() override;
25 std::shared_ptr<ossia::time_process> process() const override;
26
27 QQmlScriptString startCond() const;
28 QQmlScriptString endCond() const;
29 QQmlScriptString startTrig() const;
30 QQmlScriptString endTrig() const;
31
32public:
33 void setInterval(qml_interval* interval);
34 W_SLOT(setInterval);
35
36 void setStartCond(QQmlScriptString s);
37 W_SLOT(setStartCond);
38 void setEndCond(QQmlScriptString s);
39 W_SLOT(setEndCond);
40 void setStartTrig(QQmlScriptString s);
41 W_SLOT(setStartTrig);
42 void setEndTrig(QQmlScriptString s);
43 W_SLOT(setEndTrig);
44
45public:
46 void intervalChanged(qml_interval* interval)
47 E_SIGNAL(OSSIA_EXPORT, intervalChanged, interval);
48 void startTrigChanged(QQmlScriptString arg_1)
49 E_SIGNAL(OSSIA_EXPORT, startTrigChanged, arg_1);
50 void endTrigChanged(QQmlScriptString arg_1)
51 E_SIGNAL(OSSIA_EXPORT, endTrigChanged, arg_1);
52 void startCondChanged(QQmlScriptString arg_1)
53 E_SIGNAL(OSSIA_EXPORT, startCondChanged, arg_1);
54 void endCondChanged(QQmlScriptString arg_1)
55 E_SIGNAL(OSSIA_EXPORT, endCondChanged, arg_1);
56
57private:
58 void reset_impl() override;
59 std::shared_ptr<ossia::loop> m_impl;
60 qml_interval* m_interval{};
61 QQmlScriptString m_startCond, m_startTrig, m_endCond, m_endTrig;
62
63 W_PROPERTY(
64 QQmlScriptString, endCond READ endCond WRITE setStartCond NOTIFY endCondChanged)
65
66 W_PROPERTY(
67 QQmlScriptString,
68 startCond READ startCond WRITE setStartCond NOTIFY startCondChanged)
69
70 W_PROPERTY(
71 QQmlScriptString, endTrig READ endTrig WRITE setStartTrig NOTIFY endTrigChanged)
72
73 W_PROPERTY(
74 QQmlScriptString,
75 startTrig READ startTrig WRITE setStartTrig NOTIFY startTrigChanged)
76
77 W_PROPERTY(
78 qml_interval*, interval READ interval WRITE setInterval NOTIFY intervalChanged)
79};
80}
81}
Definition git_info.h:7