fixed recent files navigation.

This commit is contained in:
morkt 2015-10-28 23:10:43 +04:00
parent 0b0d27c628
commit d1c8038d85

View File

@ -746,11 +746,13 @@ namespace GARbro.GUI
private void OpenFile (string filename) private void OpenFile (string filename)
{ {
if (filename == CurrentPath) if (filename == CurrentPath || string.IsNullOrEmpty (filename))
return; return;
try try
{ {
PushViewModel (GetNewViewModel (filename)); VFS.FullPath = new string[] { filename, "" };
var vm = new DirectoryViewModel (VFS.FullPath, VFS.GetFiles(), VFS.IsVirtual);
PushViewModel (vm);
if (null != VFS.CurrentArchive) if (null != VFS.CurrentArchive)
SetStatusText (VFS.CurrentArchive.Description); SetStatusText (VFS.CurrentArchive.Description);
lv_SelectItem (0); lv_SelectItem (0);