aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/Menu.js8
-rw-r--r--src/lib/Tray.js6
2 files changed, 9 insertions, 5 deletions
diff --git a/src/lib/Menu.js b/src/lib/Menu.js
index d01666d49..703060dc1 100644
--- a/src/lib/Menu.js
+++ b/src/lib/Menu.js
@@ -22,10 +22,14 @@ const template = [
22 role: 'cut', 22 role: 'cut',
23 }, 23 },
24 { 24 {
25 role: 'copy', 25 label: 'Copy',
26 accelerator: 'Cmd+C',
27 selector: 'copy:',
26 }, 28 },
27 { 29 {
28 role: 'paste', 30 label: 'Paste',
31 accelerator: 'Cmd+V',
32 selector: 'paste:',
29 }, 33 },
30 { 34 {
31 role: 'pasteandmatchstyle', 35 role: 'pasteandmatchstyle',
diff --git a/src/lib/Tray.js b/src/lib/Tray.js
index 2efe71a71..588fa75bf 100644
--- a/src/lib/Tray.js
+++ b/src/lib/Tray.js
@@ -1,4 +1,4 @@
1import { app, Tray, Menu, systemPreferences } from 'electron'; 1import { app, Tray, Menu, systemPreferences, nativeImage } from 'electron';
2import path from 'path'; 2import path from 'path';
3 3
4const FILE_EXTENSION = process.platform === 'win32' ? 'ico' : 'png'; 4const FILE_EXTENSION = process.platform === 'win32' ? 'ico' : 'png';
@@ -78,8 +78,8 @@ export default class TrayIcon {
78 platform = `${platform}-dark`; 78 platform = `${platform}-dark`;
79 } 79 }
80 80
81 return path.join( 81 return nativeImage.createFromPath(path.join(
82 __dirname, '..', 'assets', 'images', type, platform, `${asset}.${FILE_EXTENSION}`, 82 __dirname, '..', 'assets', 'images', type, platform, `${asset}.${FILE_EXTENSION}`),
83 ); 83 );
84 } 84 }
85} 85}