nw.js 0.13 :
nw.Shell.showItemInFolder(fullpath);
< 0,13:
var gui = require('nw.gui');
gui.Shell.showItemInFolder(fullpath);
, . , .
c:\foo\bar.txt, foo bar.txt. strong > .
c:\foo\foo2, foo foo2 ( foo2, ).
, node ( fs), node module (utils.js) :
exports.getFullPath = function(fileName) {
var path = require('path');
return path.resolve(__dirname, fileName);
}
:
function openFolder(path) {
var utils = require('./utils');
var fullpath = utils.getFullPath(path);
nw.Shell.showItemInFolder(fullpath);
}