make the rom open filter remember its last option used in this bizhawk session, like how most other programs work.
This commit is contained in:
parent
ab46a076f2
commit
83a06c4f63
|
@ -2902,6 +2902,7 @@ namespace BizHawk.MultiClient
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int LastOpenRomFilter = 0;
|
||||||
private void OpenROM()
|
private void OpenROM()
|
||||||
{
|
{
|
||||||
var ofd = new OpenFileDialog();
|
var ofd = new OpenFileDialog();
|
||||||
|
@ -2946,8 +2947,10 @@ namespace BizHawk.MultiClient
|
||||||
"Genesis (experimental)", "*.gen;*.md;*.smd;*.bin;*.cue;%ARCH%",
|
"Genesis (experimental)", "*.gen;*.md;*.smd;*.bin;*.cue;%ARCH%",
|
||||||
"All Files", "*.*");
|
"All Files", "*.*");
|
||||||
}
|
}
|
||||||
|
|
||||||
ofd.RestoreDirectory = false;
|
ofd.RestoreDirectory = false;
|
||||||
|
ofd.FilterIndex = LastOpenRomFilter;
|
||||||
|
|
||||||
Global.Sound.StopSound();
|
Global.Sound.StopSound();
|
||||||
var result = ofd.ShowDialog();
|
var result = ofd.ShowDialog();
|
||||||
Global.Sound.StartSound();
|
Global.Sound.StartSound();
|
||||||
|
@ -2955,6 +2958,7 @@ namespace BizHawk.MultiClient
|
||||||
return;
|
return;
|
||||||
var file = new FileInfo(ofd.FileName);
|
var file = new FileInfo(ofd.FileName);
|
||||||
Global.Config.LastRomPath = file.DirectoryName;
|
Global.Config.LastRomPath = file.DirectoryName;
|
||||||
|
LastOpenRomFilter = ofd.FilterIndex;
|
||||||
LoadRom(file.FullName);
|
LoadRom(file.FullName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue