Cleanup, extend ParseUtility to dict keys

This commit is contained in:
Sinai
2021-05-09 02:22:03 +10:00
parent c04a864b74
commit 7b700cbe55
19 changed files with 44 additions and 36 deletions

View File

@ -41,10 +41,10 @@ namespace UnityExplorer.UI.CacheObject
this.DisplayedKey = key.TryCast();
var type = DisplayedKey.GetType();
if (type == typeof(string) || (type.IsPrimitive && !(type == typeof(bool))))
if (ParseUtility.CanParse(type))
{
KeyInputWanted = true;
KeyInputText = DisplayedKey.ToString();
KeyInputText = ParseUtility.ToStringForInput(DisplayedKey, type);
KeyInputTypeText = SignatureHighlighter.Parse(type, false);
}
else