Lua Registered Functions dialog - fix bug where Call and Remove were affecting the wrong scripts
This commit is contained in:
parent
175ed75553
commit
b2e341e2df
|
@ -93,10 +93,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
|
||||
public int Column
|
||||
{
|
||||
get
|
||||
{
|
||||
return _column;
|
||||
}
|
||||
get { return _column; }
|
||||
set
|
||||
{
|
||||
if (_column == value)
|
||||
|
@ -109,10 +106,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
|
||||
public bool Descending
|
||||
{
|
||||
get
|
||||
{
|
||||
return _desc;
|
||||
}
|
||||
get { return _desc; }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -63,7 +63,8 @@ namespace BizHawk.Client.EmuHawk
|
|||
{
|
||||
foreach (int index in indices)
|
||||
{
|
||||
GlobalWin.Tools.LuaConsole.LuaImp.RegisteredFunctions[index].Call();
|
||||
string guid = FunctionView.Items[index].SubItems[2].Text;
|
||||
GlobalWin.Tools.LuaConsole.LuaImp.RegisteredFunctions[guid].Call();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -75,7 +76,8 @@ namespace BizHawk.Client.EmuHawk
|
|||
{
|
||||
foreach (int index in indices)
|
||||
{
|
||||
NamedLuaFunction nlf = GlobalWin.Tools.LuaConsole.LuaImp.RegisteredFunctions[index];
|
||||
string guid = FunctionView.Items[index].SubItems[2].Text;
|
||||
NamedLuaFunction nlf = GlobalWin.Tools.LuaConsole.LuaImp.RegisteredFunctions[guid];
|
||||
GlobalWin.Tools.LuaConsole.LuaImp.RegisteredFunctions.RemoveFunction(nlf);
|
||||
}
|
||||
PopulateListView();
|
||||
|
|
Loading…
Reference in New Issue