Data model debugger - Added module filtering

Data model debugger - Added search input (disabled & not yet implemented)
Data model debugger - Finished list support
This commit is contained in:
Robert committed 2020-06-30 11:50:40 +02:00
1 parent ac45c4d5d3
commit 3bc1da8ca6
10 files changed
+198 -47

No files matched your search

@@ -10,11 +10,16 @@ namespace Artemis.UI.DataModelVisualization
{
public abstract class DataModelVisualizationViewModel : PropertyChangedBase
{
public PropertyInfo PropertyInfo { get; protected set; }
public DataModelPropertyAttribute PropertyDescription { get; protected set; }
public PropertyInfo PropertyInfo { get; protected set; }
public Type PropertyType { get; set; }
public DataModelVisualizationViewModel Parent { get; protected set; }
public object Model { get; set; }
public bool IsListProperty { get; set; }
public string ListDescription { get; set; }
public abstract void Update();
protected DataModelVisualizationViewModel CreateChild(PropertyInfo propertyInfo)
@@ -59,5 +64,20 @@ namespace Artemis.UI.DataModelVisualization
return null;
}
protected void UpdateListStatus()
{
if (Parent is DataModelListViewModel listViewModel)
{
IsListProperty = true;
ListDescription = $"List item [{listViewModel.List.IndexOf(Model)}]";
PropertyType = Model.GetType();
}
else
{
IsListProperty = false;
PropertyType = PropertyInfo?.PropertyType;
}
}
}
}