2023-10-02 18:49:24 +00:00
|
|
|
using ImGuiNET;
|
|
|
|
using Raylib_cs;
|
|
|
|
using rlImGui_cs;
|
|
|
|
|
|
|
|
namespace Shoko;
|
|
|
|
|
|
|
|
class Program
|
|
|
|
{
|
|
|
|
static void Main(string[] args)
|
|
|
|
{
|
|
|
|
Raylib.SetConfigFlags(ConfigFlags.FLAG_WINDOW_RESIZABLE | ConfigFlags.FLAG_WINDOW_MAXIMIZED);
|
|
|
|
Raylib.InitWindow(1024, 768, "Shoko");
|
2023-10-03 19:52:26 +00:00
|
|
|
|
|
|
|
rlImGui.BeginInitImGui();
|
|
|
|
bool quit = MainUI.Load();
|
|
|
|
rlImGui.EndInitImGui();
|
|
|
|
|
2023-10-02 18:49:24 +00:00
|
|
|
if(args.Length > 0)
|
|
|
|
foreach (var arg in args)
|
|
|
|
MainUI.NewTab(arg);
|
2023-10-03 19:52:26 +00:00
|
|
|
|
2023-10-02 18:49:24 +00:00
|
|
|
while(!Raylib.WindowShouldClose() && quit)
|
|
|
|
{
|
|
|
|
Raylib.BeginDrawing();
|
|
|
|
Raylib.ClearBackground(Color.WHITE);
|
|
|
|
rlImGui.Begin();
|
|
|
|
|
|
|
|
quit = MainUI.Render();
|
|
|
|
|
|
|
|
rlImGui.End();
|
|
|
|
Raylib.EndDrawing();
|
|
|
|
}
|
|
|
|
rlImGui.Shutdown();
|
|
|
|
Raylib.CloseWindow();
|
|
|
|
}
|
|
|
|
}
|