mirror of
https://github.com/tuyoogame/YooAsset.git
synced 2026-07-01 11:13:42 +00:00
update UIElements
展示单位Units
This commit is contained in:
@@ -46,6 +46,11 @@ namespace YooAsset.Editor
|
||||
/// </summary>
|
||||
public bool Counter = false;
|
||||
|
||||
/// <summary>
|
||||
/// 展示单位
|
||||
/// </summary>
|
||||
public string Units = string.Empty;
|
||||
|
||||
public ColumnStyle(Length width)
|
||||
{
|
||||
if (width.value > MaxValue)
|
||||
|
||||
@@ -214,6 +214,16 @@ namespace YooAsset.Editor
|
||||
}
|
||||
}
|
||||
|
||||
// 设置展示单位
|
||||
foreach (var column in _columns)
|
||||
{
|
||||
if (string.IsNullOrEmpty(column.ColumnStyle.Units) == false)
|
||||
{
|
||||
var toobarButton = GetHeaderElement(column.ElementName) as ToolbarButton;
|
||||
toobarButton.text = $"{toobarButton.text} ({column.ColumnStyle.Units})";
|
||||
}
|
||||
}
|
||||
|
||||
// 设置升降符号
|
||||
if (string.IsNullOrEmpty(_sortingHeader) == false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user