Merge branch 'center-set-type' of https://github.com/Tryibion/FlaxEngine into Tryibion-center-set-type

This commit is contained in:
Wojtek Figat
2023-02-09 09:39:40 +01:00

View File

@@ -645,7 +645,7 @@ namespace FlaxEditor.CustomEditors.Dedicated
}
cm.ItemClicked += controlType => SetType((ScriptType)controlType.Tag);
cm.SortItems();
cm.Show(button.Parent, button.BottomLeft);
cm.Show(button.Parent, button.BottomLeft - new Float2((cm.Width - button.Width) / 2, 0));
}
private void SetType(ref ScriptType controlType, UIControl uiControl)