fix Show In File Manager function handling under Linux - close #151

This commit is contained in:
Vadim Lopatin 2016-01-26 16:33:44 +03:00
parent bc7bcfa0a3
commit 73d38d0906
2 changed files with 3 additions and 2 deletions

View File

@ -1218,11 +1218,12 @@ class SDLPlatform : Platform {
} else {
// TODO: implement for POSIX
if (normalized.isFile)
normalized = normalized.baseName;
normalized = normalized.dirName;
string exe = "xdg-open";
string[] args;
args ~= exe;
args ~= normalized;
Log.d("Executing ", args);
auto pid = spawnProcess(args);
wait(pid);
return true;

View File

@ -727,7 +727,7 @@ class GridWidgetBase : ScrollWidgetBase, GridModelAdapter, MenuItemActionHandler
x -= _clientRect.left;
y -= _clientRect.top;
pointToCell(x, y, col, row, rc);
MenuItem item = getCellPopupMenu(col, row);
MenuItem item = getCellPopupMenu(col - _headerCols, row - _headerRows);
if (!item)
return false;
return true;