Logic cleanup for file dialog.

This commit is contained in:
2022-12-16 17:48:43 +08:00
parent b0c70bc62e
commit e6d94f248c
3 changed files with 35 additions and 47 deletions

View File

@@ -118,7 +118,7 @@ namespace Cryville.Common.Unity {
fdialog = GameObject.Instantiate<GameObject>(Resources.Load<GameObject>("Common/FileDialog")).GetComponent<FileDialog>();
fdialog.Filter = filter;
fdialog.CurrentDirectory = ContextPath;
fdialog.Callback = () => OnFileDialogClosed();
fdialog.OnClose += OnFileDialogClosed;
}
editor.SetDescription(PropertyName, desc);
UpdateValue();