mirror of
https://github.com/Stone-Red-Code/RemSox.git
synced 2026-09-06 07:46:29 +02:00
Add windowed terminal, basic text, rectangle rendering, and keyboard events
This commit is contained in:
@@ -5,6 +5,7 @@ using System.Drawing;
|
||||
using System.Linq;
|
||||
using Cosmos.Kernel.System.Graphics;
|
||||
using Cosmos.Kernel.System.Mouse;
|
||||
using Cosmos.Kernel.System.Keyboard;
|
||||
using RemSox.Processing;
|
||||
using RemSox.UI.GUI.Rendering;
|
||||
|
||||
@@ -51,6 +52,11 @@ public static class WindowManager
|
||||
|
||||
wasLeftButtonDown = leftButtonDown;
|
||||
|
||||
if (KeyboardManager.TryReadKey(out KeyEvent keyEvent))
|
||||
{
|
||||
focusedWindow?.HandleKeyEvent(keyEvent);
|
||||
}
|
||||
|
||||
Canvas canvas = FullScreenCanvas.GetFullScreenCanvas();
|
||||
CanvasRenderSource.CompositeAndDisplay(canvas, pointerPosition);
|
||||
|
||||
@@ -86,6 +92,8 @@ public static class WindowManager
|
||||
{
|
||||
processWindows.Remove(window);
|
||||
}
|
||||
|
||||
renderSource.Render(new[] { new RenderCommand { WindowId = window.Id, ElementId = window.Id, ElementType = "WindowClose", Position = window.Position, Properties = new Dictionary<string, object?>() } });
|
||||
}
|
||||
|
||||
public static List<Window> GetWindowsForProcess(Process process)
|
||||
|
||||
Reference in New Issue
Block a user