Layer timeline - Show keyframes of collapsed groups

Profile editor - Don't reload UI elements on undo/redo if there's nothing to undo/redo
Layer properties - Properly show/hide properties
This commit is contained in:
SpoinkyNL committed 2020-05-29 17:21:29 +02:00
1 parent e6080eb897
commit 22ecf5028d
20 files changed
+182 -83

No files matched your search

@@ -1,4 +1,5 @@
using System.Collections.Generic;
using System;
using System.Collections.Generic;
using System.Linq;
using Artemis.Core.Models.Profile.LayerProperties;
using Artemis.Core.Models.Profile.LayerProperties.Attributes;
@@ -33,6 +34,8 @@ namespace Artemis.UI.Screens.Module.ProfileEditor.LayerProperties
else
PropertyDescription.Name = $"Unknown {typeof(T).Name} property";
}
LayerProperty.VisibilityChanged += LayerPropertyOnVisibilityChanged;
}
public override bool IsVisible => !LayerProperty.IsHidden;
@@ -51,6 +54,8 @@ namespace Artemis.UI.Screens.Module.ProfileEditor.LayerProperties
{
TreePropertyViewModel.Dispose();
TimelinePropertyViewModel.Dispose();
LayerProperty.VisibilityChanged -= LayerPropertyOnVisibilityChanged;
}
public void SetCurrentValue(T value, bool saveChanges)
@@ -61,6 +66,11 @@ namespace Artemis.UI.Screens.Module.ProfileEditor.LayerProperties
else
ProfileEditorService.UpdateProfilePreview();
}
private void LayerPropertyOnVisibilityChanged(object? sender, EventArgs e)
{
NotifyOfPropertyChange(nameof(IsVisible));
}
}
public abstract class LayerPropertyViewModel : LayerPropertyBaseViewModel