summaryrefslogtreecommitdiff
path: root/src/lua/include/lua_registry.hpp
diff options
context:
space:
mode:
authorjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
committerjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
commit1573a8c4cde1cd9528b422b2dcc598e37ffe94a7 (patch)
treed162822b8fd7054f81bace0c7a65ab4d5e6f93ef /src/lua/include/lua_registry.hpp
parenta231fd1c8afedbeb14b0bc77d76bad61db986059 (diff)
downloadtangara-fw-1573a8c4cde1cd9528b422b2dcc598e37ffe94a7.tar.gz
WIP merge cyclically dependent components into one big component
Diffstat (limited to 'src/lua/include/lua_registry.hpp')
-rw-r--r--src/lua/include/lua_registry.hpp51
1 files changed, 0 insertions, 51 deletions
diff --git a/src/lua/include/lua_registry.hpp b/src/lua/include/lua_registry.hpp
deleted file mode 100644
index abc5063e..00000000
--- a/src/lua/include/lua_registry.hpp
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright 2023 jacqueline <me@jacqueline.id.au>
- *
- * SPDX-License-Identifier: GPL-3.0-only
- */
-
-#pragma once
-
-#include <memory>
-#include <string>
-
-#include "lua.hpp"
-
-#include "bridge.hpp"
-#include "lua_thread.hpp"
-#include "service_locator.hpp"
-
-namespace lua {
-
-class Registry {
- public:
- static auto instance(system_fsm::ServiceLocator&) -> Registry&;
-
- auto uiThread() -> std::shared_ptr<LuaThread>;
- auto newThread() -> std::shared_ptr<LuaThread>;
-
- auto AddPropertyModule(
- const std::string&,
- std::vector<std::pair<std::string, std::variant<LuaFunction, Property*>>>)
- -> void;
-
- Registry(const Registry&) = delete;
- Registry& operator=(const Registry&) = delete;
-
- private:
- Registry(system_fsm::ServiceLocator&);
-
- system_fsm::ServiceLocator& services_;
- std::unique_ptr<Bridge> bridge_;
-
- std::shared_ptr<LuaThread> ui_thread_;
- std::list<std::weak_ptr<LuaThread>> threads_;
-
- std::vector<
- std::pair<std::string,
- std::vector<std::pair<std::string,
- std::variant<LuaFunction, Property*>>>>>
- modules_;
-};
-
-} // namespace lua