mirror of
https://github.com/Leonmmcoset/CMLeonOS.git
synced 2026-04-21 19:24:00 +00:00
修复些bug
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
using CMLeonOS;
|
||||
using CMLeonOS;
|
||||
using CMLeonOS.Gui.UILib;
|
||||
using Cosmos.System.Graphics;
|
||||
using System.Drawing;
|
||||
@@ -17,6 +17,10 @@ namespace CMLeonOS.Gui.Apps.CodeStudio
|
||||
this.wm = wm;
|
||||
}
|
||||
|
||||
[IL2CPU.API.Attribs.ManifestResourceStream(ResourceName = "CMLeonOS.Gui.Resources.AppIcons.CodeStudio.bmp")]
|
||||
private static byte[] _iconBytes;
|
||||
private static Bitmap iconBitmap = new Bitmap(_iconBytes);
|
||||
|
||||
[IL2CPU.API.Attribs.ManifestResourceStream(ResourceName = "CMLeonOS.Gui.Resources.CodeStudio.Run.bmp")]
|
||||
private static byte[] _runBytes;
|
||||
private static Bitmap runBitmap = new Bitmap(_runBytes);
|
||||
@@ -175,6 +179,9 @@ namespace CMLeonOS.Gui.Apps.CodeStudio
|
||||
ILuaState lua = LuaAPI.NewState();
|
||||
lua.L_OpenLibs();
|
||||
|
||||
LuaGuiLibrary.Initialize(wm, process);
|
||||
LuaGuiLibrary.Register(lua);
|
||||
|
||||
lua.PushCSharpFunction(L =>
|
||||
{
|
||||
int n = L.GetTop();
|
||||
@@ -275,6 +282,7 @@ namespace CMLeonOS.Gui.Apps.CodeStudio
|
||||
internal void Start()
|
||||
{
|
||||
mainWindow = new AppWindow(process, 96, 96, 800, 600);
|
||||
mainWindow.Icon = iconBitmap;
|
||||
mainWindow.Clear(Theme.Background);
|
||||
mainWindow.Closing = process.TryStop;
|
||||
mainWindow.CanResize = true;
|
||||
|
||||
Reference in New Issue
Block a user