SHA256
Implement O5Kit
This commit is contained in:
8 files changed
+99
-175
No files matched your search
@@ -0,0 +1,51 @@
|
||||
using ADOFAIRenderer.Localization;
|
||||
using O5Kit.Core;
|
||||
using O5Kit.Factory;
|
||||
using UnityEngine;
|
||||
|
||||
namespace ADOFAIRenderer.UI.Window;
|
||||
|
||||
internal static class RenderConfigWindow
|
||||
{
|
||||
private static O5Window? _configWindow;
|
||||
|
||||
// 윈도우 만드는 메서드...
|
||||
public static void CreateWindow()
|
||||
{
|
||||
if (_configWindow == null)
|
||||
{
|
||||
_configWindow = RendererUIManager.Instance.WindowManager.Create(new O5WindowOptions
|
||||
{
|
||||
Id = "RendererMod_RenderConfig",
|
||||
Title = LocalizationManager.Get("ui.render_config.window_title"),
|
||||
Size = new Vector2(580f, 420f),
|
||||
Draggable = true,
|
||||
Resizable = true,
|
||||
ShowCloseButton = true
|
||||
});
|
||||
|
||||
_configWindow.CloseRequested += win =>
|
||||
{
|
||||
win.Rect.gameObject.SetActive(false);
|
||||
};
|
||||
|
||||
BuildUI(_configWindow.Content);
|
||||
}
|
||||
|
||||
SetWindowActive(true);
|
||||
}
|
||||
|
||||
private static void BuildUI(RectTransform content)
|
||||
{
|
||||
var (viewport, scrollContent, scroller) =
|
||||
O5Factory.ScrollView(RendererUIManager.Context, content, spacing: 10f);
|
||||
|
||||
// TODO: RenderFPS double 입력칸, VideoFPS double 입력칸, RenderWidth int (>0) 입력칸, RenderHeight int (>0) 입력칸, Video Encoding Config, Audio Encoding Config, Delay After Level End double (>=0) 입력칸, Show Judgement Toggle, Global Settings, Advanced Settings, Go Render 버튼
|
||||
// NOTE: 한 가로줄에 두개씩
|
||||
}
|
||||
|
||||
private static void SetWindowActive(bool enabled)
|
||||
{
|
||||
_configWindow?.Rect.gameObject.SetActive(enabled);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user