mirror of
https://github.com/Artemis-RGB/Artemis
synced 2025-12-13 05:48:35 +00:00
Storage - Fix profile order not loading/saving
This commit is contained in:
parent
8d7af6bb85
commit
4c2eca29cc
@ -167,7 +167,7 @@ public class ProfileCategory : CorePropertyChanged, IStorageModel
|
|||||||
IsSuspended = Entity.IsSuspended;
|
IsSuspended = Entity.IsSuspended;
|
||||||
Order = Entity.Order;
|
Order = Entity.Order;
|
||||||
|
|
||||||
ProfileConfigurations = new ReadOnlyCollection<ProfileConfiguration>(Entity.ProfileConfigurations.Select(pc => new ProfileConfiguration(this, pc)).ToList());
|
ProfileConfigurations = new ReadOnlyCollection<ProfileConfiguration>(Entity.ProfileConfigurations.Select(pc => new ProfileConfiguration(this, pc)).OrderBy(pc => pc.Order).ToList());
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
@ -180,8 +180,11 @@ public class ProfileCategory : CorePropertyChanged, IStorageModel
|
|||||||
|
|
||||||
Entity.ProfileConfigurations.Clear();
|
Entity.ProfileConfigurations.Clear();
|
||||||
foreach (ProfileConfiguration profileConfiguration in ProfileConfigurations)
|
foreach (ProfileConfiguration profileConfiguration in ProfileConfigurations)
|
||||||
|
{
|
||||||
|
profileConfiguration.Save();
|
||||||
Entity.ProfileConfigurations.Add(profileConfiguration.Entity);
|
Entity.ProfileConfigurations.Add(profileConfiguration.Entity);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user