Add context menu for cut, copy, paste, select all
This commit is contained in:
parent
f57e2a94ef
commit
d010d09ef4
|
@ -174,6 +174,12 @@ var MattermostView = React.createClass({
|
||||||
var configFile = remote.getGlobal('config-file');
|
var configFile = remote.getGlobal('config-file');
|
||||||
var config = settings.readFileSync(configFile);
|
var config = settings.readFileSync(configFile);
|
||||||
|
|
||||||
|
var contextMenu = require('./menus/context');
|
||||||
|
var menu = contextMenu.createDefault();
|
||||||
|
window.addEventListener('contextmenu', function(e) {
|
||||||
|
menu.popup(remote.getCurrentWindow());
|
||||||
|
}, false);
|
||||||
|
|
||||||
var showUnreadBadge = function(unreadCount) {
|
var showUnreadBadge = function(unreadCount) {
|
||||||
switch (process.platform) {
|
switch (process.platform) {
|
||||||
case 'win32':
|
case 'win32':
|
||||||
|
|
|
@ -172,6 +172,12 @@ var TeamListItemNew = React.createClass({
|
||||||
|
|
||||||
var configFile = remote.getGlobal('config-file');
|
var configFile = remote.getGlobal('config-file');
|
||||||
|
|
||||||
|
var contextMenu = require('./menus/context');
|
||||||
|
var menu = contextMenu.createDefault();
|
||||||
|
window.addEventListener('contextmenu', function(e) {
|
||||||
|
menu.popup(remote.getCurrentWindow());
|
||||||
|
}, false);
|
||||||
|
|
||||||
ReactDOM.render(
|
ReactDOM.render(
|
||||||
<SettingsPage configFile={ configFile } />,
|
<SettingsPage configFile={ configFile } />,
|
||||||
document.getElementById('content')
|
document.getElementById('content')
|
||||||
|
|
Loading…
Reference in a new issue