Skip to content

Commit

Permalink
Merge pull request JochenHeckl#27 from JochenHeckl/wip
Browse files Browse the repository at this point in the history
Add spacing above data source in inspector
  • Loading branch information
JochenHeckl authored Jul 26, 2024
2 parents ead7db0 + bd57906 commit a6dc0f3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions Editor/Scripts/DataBindingEditorStyles.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@ public static StyleSheet StyleSheet
}
}

internal static void DataSourceStyle(VisualElement visualElement)
{
visualElement.style.marginTop = 12;
}

internal static void ErrorMessageStyle(VisualElement visualElement)
{
visualElement.style.marginTop = 12;
Expand Down
2 changes: 1 addition & 1 deletion Editor/Scripts/Editors/ComponentPropertyBindingEditor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ internal class ComponentPropertyBindingEditor : BindingEditor<ComponentPropertyB
{
private DropdownField targetComponentSelectionDropdownField;

private readonly Type dataSourceType;
private new readonly Type dataSourceType;
private readonly PropertyInfo[] bindableDataSourceProperties;
private readonly Action bindingChanged;

Expand Down
2 changes: 2 additions & 0 deletions Editor/Scripts/ViewEditorBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,8 @@ Action<Type> handleDataSourceTypeChanged
dataSource.Add(MakeOpenDataSourceButton(currentDataSourceType));
}

DataBindingEditorStyles.DataSourceStyle(dataSource);

return dataSource;
}
}
Expand Down

0 comments on commit a6dc0f3

Please sign in to comment.