Permalink
Browse files

fix(clipboard): copy/cut/paste

  • Loading branch information...
h13i32maru committed Sep 2, 2018
1 parent 7219ab5 commit 4e7388e9e35c065183a806608eb33508a97c3cdd
Showing with 9 additions and 2 deletions.
  1. +8 −0 src/BrowserViewProxy.js
  2. +1 −2 src/Electron/Component/BrowserViewComponent.js
@@ -36,6 +36,14 @@ export default class BrowserViewProxy {
return this._webContents;
}
static cut() {
this._webContents.cut();
}
static paste() {
this._webContents.paste();
}
static canGoBack() {
return this._webContents.canGoBack();
}
@@ -347,8 +347,7 @@ export default class WebViewComponent extends React.Component {
menu.append(new MenuItem({
label: 'Copy text',
click: ()=>{
//clipboard.writeText(data.text);
webView.copy();
clipboard.writeText(data.text);
}
}));

0 comments on commit 4e7388e

Please sign in to comment.