36 lines
674 B
C++
36 lines
674 B
C++
/*
|
|
* Copyright 2016 - 2022 Gary Talent (gary@drinkingtea.net). All rights reserved.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <functional>
|
|
|
|
#include <ox/std/string.hpp>
|
|
#include <ox/std/vector.hpp>
|
|
|
|
#include <nostalgia/studio/studio.hpp>
|
|
#include <nostalgia/core/context.hpp>
|
|
|
|
namespace nostalgia::studio {
|
|
|
|
class ItemMaker;
|
|
|
|
struct EditorMaker {
|
|
using Func = std::function<ox::Result<class BaseEditor*>(ox::CRStringView)>;
|
|
ox::Vector<ox::String> fileTypes;
|
|
Func make;
|
|
};
|
|
|
|
class Module {
|
|
public:
|
|
virtual ~Module() noexcept = default;
|
|
|
|
virtual ox::Vector<EditorMaker> editors(core::Context *ctx);
|
|
|
|
virtual ox::Vector<ox::UniquePtr<ItemMaker>> itemMakers(core::Context*);
|
|
|
|
};
|
|
|
|
}
|