mirror of
https://github.com/Ottermandias/Glamourer.git
synced 2025-12-30 04:13:43 +01:00
.
This commit is contained in:
parent
80ab57e96d
commit
d1d369a56b
31 changed files with 1637 additions and 80 deletions
33
Glamourer/Gui/Tabs/DesignTab/DesignPanel.cs
Normal file
33
Glamourer/Gui/Tabs/DesignTab/DesignPanel.cs
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
using System.Numerics;
|
||||
using Glamourer.Designs;
|
||||
using Glamourer.Gui.Customization;
|
||||
using OtterGui.Raii;
|
||||
|
||||
namespace Glamourer.Gui.Tabs.DesignTab;
|
||||
|
||||
public class DesignPanel
|
||||
{
|
||||
private readonly DesignFileSystemSelector _selector;
|
||||
private readonly DesignManager _manager;
|
||||
private readonly CustomizationDrawer _customizationDrawer;
|
||||
|
||||
public DesignPanel(DesignFileSystemSelector selector, CustomizationDrawer customizationDrawer, DesignManager manager)
|
||||
{
|
||||
_selector = selector;
|
||||
_customizationDrawer = customizationDrawer;
|
||||
_manager = manager;
|
||||
}
|
||||
|
||||
public void Draw()
|
||||
{
|
||||
var design = _selector.Selected;
|
||||
if (design == null)
|
||||
return;
|
||||
|
||||
using var child = ImRaii.Child("##panel", -Vector2.One, true);
|
||||
if (!child)
|
||||
return;
|
||||
|
||||
_customizationDrawer.Draw(design.DesignData.Customize, design.WriteProtected());
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue