Zrythm v2.0.0-DEV
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
clip_launcher.h
1// SPDX-FileCopyrightText: © 2025-2026 Alexandros Theodotou <alex@zrythm.org>
2// SPDX-License-Identifier: LicenseRef-ZrythmLicense
3
4#pragma once
5
6#include "structure/scenes/scene.h"
7
8#include <QtQmlIntegration/qqmlintegration.h>
9
10#include <nlohmann/json_fwd.hpp>
11
12namespace zrythm::structure::scenes
13{
14class ClipLauncher : public QObject
15{
16 Q_OBJECT
17 Q_PROPERTY (zrythm::structure::scenes::SceneList * scenes READ scenes CONSTANT)
18 QML_ELEMENT
19 QML_UNCREATABLE ("")
20
21public:
22 ClipLauncher (
23 arrangement::ArrangerObjectRegistry &object_registry,
24 const tracks::TrackCollection &track_collection,
25 QObject * parent = nullptr);
26
27 SceneList * scenes () const { return scene_list_.get (); }
28
29 // Scene management
30 Q_INVOKABLE Scene * addScene ();
31
32private:
33 static constexpr auto kScenesKey = "scenes"sv;
34 friend void to_json (nlohmann::json &j, const ClipLauncher &launcher);
35 friend void from_json (const nlohmann::json &j, ClipLauncher &launcher);
36
37private:
39
40 arrangement::ArrangerObjectRegistry &object_registry_;
41 const tracks::TrackCollection &track_collection_;
42};
43
44} // namespace zrythm::structure::scenes
A collection of tracks that provides a QAbstractListModel interface.
A unique pointer for QObject objects that also works with QObject-based ownership.
Definition qt.h:38