mirror of
https://github.com/Ottermandias/Glamourer.git
synced 2025-12-13 12:14:18 +01:00
Fix FixedDesign enabled/disabled status saving.
This commit is contained in:
parent
29a3f3104d
commit
0560648018
2 changed files with 8 additions and 4 deletions
|
|
@ -5,12 +5,12 @@ namespace Glamourer
|
||||||
{
|
{
|
||||||
public class GlamourerConfig : IPluginConfiguration
|
public class GlamourerConfig : IPluginConfiguration
|
||||||
{
|
{
|
||||||
public struct FixedDesign
|
public class FixedDesign
|
||||||
{
|
{
|
||||||
public string Name;
|
public string Name = string.Empty;
|
||||||
public string Path;
|
public string Path = string.Empty;
|
||||||
public uint JobGroups;
|
public uint JobGroups;
|
||||||
public bool Enabled;
|
public bool Enabled;
|
||||||
}
|
}
|
||||||
|
|
||||||
public int Version { get; set; } = 1;
|
public int Version { get; set; } = 1;
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,11 @@ namespace Glamourer.Gui
|
||||||
if (ImGui.Checkbox($"##Enabled{i}", ref tmp))
|
if (ImGui.Checkbox($"##Enabled{i}", ref tmp))
|
||||||
if (tmp && _plugin.FixedDesigns.EnableDesign(name)
|
if (tmp && _plugin.FixedDesigns.EnableDesign(name)
|
||||||
|| !tmp && _plugin.FixedDesigns.DisableDesign(name))
|
|| !tmp && _plugin.FixedDesigns.DisableDesign(name))
|
||||||
|
{
|
||||||
|
Glamourer.Config.FixedDesigns[i].Enabled = tmp;
|
||||||
Glamourer.Config.Save();
|
Glamourer.Config.Save();
|
||||||
|
}
|
||||||
|
|
||||||
raii.PopStyles();
|
raii.PopStyles();
|
||||||
raii.PopFonts();
|
raii.PopFonts();
|
||||||
ImGui.TableNextColumn();
|
ImGui.TableNextColumn();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue