Merge remote-tracking branch 'ackwell/mdl-io-triage-6'

This commit is contained in:
Ottermandias 2024-05-04 11:19:17 +02:00
commit d72008b4b9
9 changed files with 154 additions and 42 deletions

View file

@ -204,8 +204,9 @@ public class FileEditor<T>(
private void SaveButton()
{
var canSave = _changed && _currentFile != null && _currentFile.Valid;
if (ImGuiUtil.DrawDisabledButton("Save to File", Vector2.Zero,
$"Save the selected {fileType} file with all changes applied. This is not revertible.", !_changed))
$"Save the selected {fileType} file with all changes applied. This is not revertible.", !canSave))
{
compactor.WriteAllBytes(_currentPath!.File.FullName, _currentFile!.Write());
if (owner.Mod != null)