A few more bug fixes.
Reset menus when an image editor instance gets reloaded from bflim. Parent check FMAA animation files.
This commit is contained in:
parent
7f8183ca2f
commit
83a9ae7395
@ -323,7 +323,7 @@ namespace Bfres.Structs
|
|||||||
public override void OnClick(TreeView treeView) => UpdateEditor();
|
public override void OnClick(TreeView treeView) => UpdateEditor();
|
||||||
|
|
||||||
public void UpdateEditor(){
|
public void UpdateEditor(){
|
||||||
((BFRES)Parent.Parent.Parent).LoadEditors(this);
|
((BFRES)Parent?.Parent?.Parent)?.LoadEditors(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ResFile GetResFile()
|
public ResFile GetResFile()
|
||||||
|
@ -589,8 +589,6 @@ namespace Bfres.Structs
|
|||||||
surf.swizzle = texture.Swizzle;
|
surf.swizzle = texture.Swizzle;
|
||||||
surf.numArray = texture.ArrayLength;
|
surf.numArray = texture.ArrayLength;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (Tex2Swizzle != 0)
|
if (Tex2Swizzle != 0)
|
||||||
surf.mip_swizzle = Tex2Swizzle;
|
surf.mip_swizzle = Tex2Swizzle;
|
||||||
|
|
||||||
|
@ -107,6 +107,7 @@ namespace FirstPlugin
|
|||||||
|
|
||||||
form.Text = Text;
|
form.Text = Text;
|
||||||
form.Dock = DockStyle.Fill;
|
form.Dock = DockStyle.Fill;
|
||||||
|
form.ResetMenus();
|
||||||
form.AddFileContextEvent("Save", Save);
|
form.AddFileContextEvent("Save", Save);
|
||||||
form.AddFileContextEvent("Replace", Replace);
|
form.AddFileContextEvent("Replace", Replace);
|
||||||
form.LoadProperties(prop);
|
form.LoadProperties(prop);
|
||||||
|
@ -141,6 +141,12 @@ namespace Toolbox.Library.Forms
|
|||||||
|
|
||||||
public bool ShowChannelEditor = true;
|
public bool ShowChannelEditor = true;
|
||||||
|
|
||||||
|
public void ResetMenus()
|
||||||
|
{
|
||||||
|
fileToolStripMenuItem.DropDownItems.Clear();
|
||||||
|
fileToolStripMenuItem.DropDownItems.Add(exportToolStripMenuItem);
|
||||||
|
}
|
||||||
|
|
||||||
public void AddFileContextEvent(string Name, EventHandler eventHandler, bool Checked = false)
|
public void AddFileContextEvent(string Name, EventHandler eventHandler, bool Checked = false)
|
||||||
{
|
{
|
||||||
if (Name == "Save")
|
if (Name == "Save")
|
||||||
|
Loading…
Reference in New Issue
Block a user