use gizmo to load roms from drag&drop and commandline (file>open already magically worked, due to explorer I guess)
This commit is contained in:
parent
b2cfc199cc
commit
edc3cea302
|
@ -4,7 +4,9 @@ using System.IO;
|
|||
using System.Windows.Forms;
|
||||
using System.Reflection;
|
||||
using System.Linq;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using BizHawk.Common;
|
||||
|
||||
using BizHawk.Emulation.Common;
|
||||
using BizHawk.Emulation.Common.IEmulatorExtensions;
|
||||
|
@ -165,7 +167,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
|
||||
#endregion
|
||||
|
||||
private void ProcessFileList(string[] fileList, ref Dictionary<LoadOrdering, List<FileInformation>> sortedFiles, string archive = null)
|
||||
private void ProcessFileList(IEnumerable<string> fileList, ref Dictionary<LoadOrdering, List<FileInformation>> sortedFiles, string archive = null)
|
||||
{
|
||||
foreach (string file in fileList)
|
||||
{
|
||||
|
@ -288,7 +290,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
sortedFiles.Add(value, new List<FileInformation>());
|
||||
}
|
||||
|
||||
ProcessFileList(filePaths, ref sortedFiles, null);
|
||||
ProcessFileList(HawkFile.Util_ResolveLinks(filePaths), ref sortedFiles, null);
|
||||
|
||||
// For each of the different types of item, if there are no items of that type, skip them.
|
||||
// If there is exactly one of that type of item, load it.
|
||||
|
|
|
@ -3386,6 +3386,8 @@ namespace BizHawk.Client.EmuHawk
|
|||
// Still needs a good bit of refactoring
|
||||
public bool LoadRom(string path, LoadRomArgs args)
|
||||
{
|
||||
path = HawkFile.Util_ResolveLink(path);
|
||||
|
||||
//default args
|
||||
if (args == null) args = new LoadRomArgs();
|
||||
|
||||
|
|
Loading…
Reference in New Issue