private void RenameFile_PopUp(EmbEntry embEntry) { RenameForm renameForm = new RenameForm(System.IO.Path.GetFileNameWithoutExtension(embEntry.Name), ".dds", String.Format("Renaming {0}", embEntry.Name), EmbFile, this, RenameForm.Mode.Texture); renameForm.ShowDialog(); if (renameForm.WasNameChanged) { embEntry.Name = renameForm.NameValue + ".dds"; } }
private void RenameFile_PopUp(Material material) { RenameForm renameForm = new RenameForm(material.Str_00, "", String.Format("Renaming {0}", material.Str_00), EmmFile, this, RenameForm.Mode.Material, 32); renameForm.ShowDialog(); if (renameForm.WasNameChanged) { material.Str_00 = renameForm.NameValue; } }
private void RenameFile_PopUp(Material material) { RenameForm renameForm = new RenameForm(material.Str_00, "", String.Format("Renaming {0}", material.Str_00), EmmFile, this, RenameForm.Mode.Material, 32); renameForm.ShowDialog(); if (renameForm.WasNameChanged) { UndoManager.Instance.AddUndo(new UndoableProperty <Material>(nameof(material.Str_00), material, material.Str_00, renameForm.NameValue, "Rename (Material)")); material.Str_00 = renameForm.NameValue; } }
private void RenameFile_PopUp(EmbEntry embEntry) { RenameForm renameForm = new RenameForm(System.IO.Path.GetFileNameWithoutExtension(embEntry.Name), ".dds", String.Format("Renaming {0}", embEntry.Name), EmbFile, this, RenameForm.Mode.Texture); renameForm.ShowDialog(); if (renameForm.WasNameChanged) { UndoManager.Instance.AddUndo(new UndoableProperty <EmbEntry>(nameof(EmbEntry.Name), embEntry, embEntry.Name, renameForm.NameValue + ".dds", "EMB Rename")); embEntry.Name = renameForm.NameValue + ".dds"; } }