/*
 * Mirai. Copyright (C) 2024 Vyn
 * This file is licensed under version 3 of the GNU General Public License (GPL-3.0-only)
 * The license can be found in the LICENSE file or at https://www.gnu.org/licenses/gpl-3.0.txt
 */

#pragma once

#include "mirai-core/Mirai.h"
#include "slint.h"
#include "ui.h"

class EditEventWindow
{

  public:
	EditEventWindow(mirai::Mirai *mirai);

	void open();
	void close();

	auto getHandle()
	{
		return this->window_;
	}

  private:
	void setupCallbacks();

	std::shared_ptr<slint::VectorModel<ui::Source>> sources_;
	slint::ComponentHandle<ui::EditEventWindow> window_ = ui::EditEventWindow::create();
	mirai::Mirai *miraiInstance_;
};
