Fixed Most Rendering
Most controls would render in the wrong location due to the OpenGL cords not being updated.
This commit is contained in:
parent
41438004d5
commit
570fa572d3
@ -4,7 +4,7 @@ using OpenTK.Graphics.OpenGL4;
|
||||
|
||||
namespace Luski.GUI.MainScreen.UI.Generic;
|
||||
|
||||
public class MessageFlow : FlowLayout
|
||||
public class MessageFlow : LuskiFlow
|
||||
{
|
||||
public override void ResizeDraw(int x, int y, int sx, int sy, int sw, int sh)
|
||||
{
|
||||
|
@ -13,7 +13,6 @@ public class ExperimentGUI : UserControl
|
||||
public DropDown<ExperimentDropButton> dd;
|
||||
private static Texture? TopOpen, BottomOpen;
|
||||
private ExperimentSelectorInfo? currentEnabled;
|
||||
private Label n;
|
||||
|
||||
private static ExperimentSelectorInfo DisabledESI = new()
|
||||
{
|
||||
@ -41,7 +40,7 @@ public class ExperimentGUI : UserControl
|
||||
Location = new(5.ScaleInt()),
|
||||
Text = ei.DisplayName
|
||||
};
|
||||
n = new(Globals.MessageFont)
|
||||
Label n = new(Globals.MessageFont)
|
||||
{
|
||||
Text = ei.Name,
|
||||
Location = new(Top.Location.X, Top.Location.Y + Top.Size.Y + Top.Location.Y),
|
||||
@ -84,7 +83,7 @@ public class ExperimentGUI : UserControl
|
||||
dd.OpenStatusChanged += b =>
|
||||
{
|
||||
BlockDraw = true;
|
||||
Size = new(base.Size.X, base.Size.Y + ( b ? dd.DropDownContainer.Size.Y : -1 * dd.DropDownContainer.Size.Y));
|
||||
SetSize(base.Size.X, base.Size.Y + ( b ? dd.DropDownContainer.Size.Y : -1 * dd.DropDownContainer.Size.Y));
|
||||
if (b)
|
||||
{
|
||||
dd.Textures[0] = TopOpen;
|
||||
@ -129,7 +128,6 @@ public class ExperimentGUI : UserControl
|
||||
base.Size = new(Globals.ms.ClientSize.X - 307.ScaleInt() - 80.ScaleInt(), 15.ScaleInt() + dd.Size.Y + dd.Location.Y );
|
||||
dd.Size = new(base.Size.X - Top.Location.X - Top.Location.X, dd.Size.Y);
|
||||
dd.ForceDistanceUpdate(this);
|
||||
|
||||
Controls.Add(Top);
|
||||
}
|
||||
|
||||
@ -147,11 +145,4 @@ public class ExperimentGUI : UserControl
|
||||
}
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
public override void ParentResize()
|
||||
{
|
||||
base.ParentResize();
|
||||
dd.Location = new(Top.Location.X, n.Location.Y + n.Size.Y + Top.Location.Y);
|
||||
dd.ForceDistanceUpdate(this);
|
||||
}
|
||||
}
|
@ -190,10 +190,8 @@ public class MainScreenWindow : Window
|
||||
private async Task OnWindowLoaded(Window arg)
|
||||
{
|
||||
BlockDraw = false;
|
||||
Console.WriteLine("start");
|
||||
string irl =
|
||||
$"https://www.jacobtech.com/Updater/GetProgramVersion?directory=Luski&branch=main&selfcontained={Globals.UpdaterSettings.SelfContained.ToString().ToLower()}&platform={Globals.UpdaterSettings.Platform}";
|
||||
Console.WriteLine(irl);
|
||||
if (Globals.UpdaterSettings.AutoUpdateCheck && new HttpClient()
|
||||
.GetAsync(
|
||||
irl)
|
||||
|
@ -22,7 +22,7 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="GraphicsManager" Version="1.1.1-alpha25" />
|
||||
<PackageReference Include="GraphicsManager" Version="1.1.1-alpha30" />
|
||||
<PackageReference Include="Luski.net" Version="2.0.1-alpha18" />
|
||||
<PackageReference Include="Updater" Version="1.0.0-alpha04" />
|
||||
</ItemGroup>
|
||||
|
Loading…
Reference in New Issue
Block a user