win: Make sure shell.showItemInFolder in called on browser side.
authorCheng Zhao <zcbenz@gmail.com>
Wed, 21 May 2014 14:31:44 +0000 (22:31 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Wed, 21 May 2014 14:31:44 +0000 (22:31 +0800)
Fixes #341.

atom/common/api/lib/clipboard.coffee
atom/common/api/lib/shell.coffee

index bad679b..99a5754 100644 (file)
@@ -1,5 +1,5 @@
 module.exports =
-  if process.platform is 'linux'
+  if process.platform is 'linux' and process.__atom_type is 'renderer'
     # On Linux we could not access clipboard in renderer process.
     require('remote').process.atomBinding 'clipboard'
   else
index 5fb935b..74acaf8 100644 (file)
@@ -1 +1,4 @@
 module.exports = process.atomBinding 'shell'
+
+if process.platform is 'win32' and process.__atom_type is 'renderer'
+  module.exports.showItemInFolder = require('remote').process.atomBinding('shell').showItemInFolder