diff --git a/docs/setup.md b/docs/setup.md index b8b0b55a..c9d4fe65 100644 --- a/docs/setup.md +++ b/docs/setup.md @@ -153,7 +153,6 @@ Below lists menu options (shortcut keys are listed in brackets, `Ctrl` becomes ` - **Paste** (Ctrl+V) - Pastes text from clipboard - **Select All** (Ctrl+A) - Select all text in input box - **Search in Team** (Ctrl+S) - Puts cursor in search box to search in the current team - - **Search in Channel** (Shift+Ctrl+S) - Puts cursor in search box to search in current channel - **View** - **Reload** (Ctrl+R) - Reload page from the server - **Clear Cache and Reload** (Ctrl+Shift+R) - Clear cached content in application and reload page @@ -172,7 +171,7 @@ Below lists menu options (shortcut keys are listed in brackets, `Ctrl` becomes ` - **Select Next Team** (Ctrl+Tab, Alt+Command+Right) - Open the right tab - **Select Previous Team** (Ctrl+Shift+Tab, Alt+Command+Left) - Open the left tab - **Help** - - ***Mattermost Docs*** Links to the official mattermost documentation + - ***Learn More*** Links to the official mattermost documentation - ***Version*** Indicate the application version diff --git a/gulpfile.js b/gulpfile.js index 5c13db4c..659ecac5 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -221,7 +221,7 @@ function makePackage(platform, arch, callback) { callback(err); } else { - if (arch === 'linux' || arch === 'all') { + if (platform === 'linux' || platform === 'all') { const dest_32 = 'release/Mattermost-linux-ia32'; const dest_64 = 'release/Mattermost-linux-x64'; fs.createReadStream('resources/icon.png').pipe(fs.createWriteStream(`${dest_32}/icon.png`)); diff --git a/package.json b/package.json index 55987a5c..b20ac4b4 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { - "name": "mattermost-desktop", + "name": "mattermost", "productName": "Mattermost", - "version": "1.4.0", + "version": "3.4.0", "description": "Mattermost Desktop application for Windows, Mac and Linux", "main": "main.js", "author": { diff --git a/src/browser/js/notification.js b/src/browser/js/notification.js index e2ab532a..8ce3a23c 100644 --- a/src/browser/js/notification.js +++ b/src/browser/js/notification.js @@ -52,7 +52,7 @@ function override(eventHandlers) { defineReadProperty(event); Notification.prototype.__defineSetter__(event, function(originalCallback) { this.notification[event] = function() { - callbackevent = { + const callbackevent = { preventDefault: function() { this.isPrevented = true; } diff --git a/src/browser/settings.jsx b/src/browser/settings.jsx index 8dd78756..e489b209 100644 --- a/src/browser/settings.jsx +++ b/src/browser/settings.jsx @@ -209,6 +209,15 @@ var SettingsPage = React.createClass({ navbar: { backgroundColor: '#fff' }, + close: { + position: 'absolute', + right: '0', + top: '10px', + fontSize: '35px', + fontWeight: 'normal', + color: '#bbb', + cursor: 'pointer' + }, heading: { textAlign: 'center', fontSize: '24px', @@ -242,9 +251,14 @@ var SettingsPage = React.createClass({ return (
-

Settings

+
+

Settings

+
+ × +
+
- +

Team Management

@@ -256,9 +270,6 @@ var SettingsPage = React.createClass({ { teams_row }
{ options_row } -
-
-
diff --git a/src/main.js b/src/main.js index 08e4b462..0bf7c3b5 100644 --- a/src/main.js +++ b/src/main.js @@ -17,19 +17,31 @@ process.on('uncaughtException', (error) => { if (process.platform === 'win32') { var cmd = process.argv[1]; + var AutoLaunch = require('auto-launch'); + var appLauncher = new AutoLaunch({ + name: 'Mattermost', + isHidden: true + }); if (cmd === '--squirrel-uninstall') { - var AutoLaunch = require('auto-launch'); - var appLauncher = new AutoLaunch({ - name: 'Mattermost', - isHidden: true - }); + // If we're uninstalling, make sure we also delete our auto launch registry key appLauncher.isEnabled().then(function(enabled) { if (enabled) appLauncher.disable(); }); } + else if (cmd === '--squirrel-install' || cmd === '--squirrel-updated') { + // If we're updating and already have an registry entry for auto launch, make sure to update the path + appLauncher.isEnabled().then(function(enabled) { + if (enabled) { + return appLauncher.disable().then(function() { + return appLauncher.enable(); + }); + } + }); + } } +app.setAppUserModelId('com.squirrel.mattermost.Mattermost'); // Use explicit AppUserModelID require('electron-squirrel-startup'); const fs = require('fs'); diff --git a/src/main/menus/app.js b/src/main/menus/app.js index 8138d271..5fd9c304 100644 --- a/src/main/menus/app.js +++ b/src/main/menus/app.js @@ -36,7 +36,7 @@ var createTemplate = function(mainWindow, config) { }, separatorItem, { role: 'quit' }] : [{ - label: 'Settings', + label: 'Settings...', accelerator: 'CmdOrCtrl+,', click: function(item, focusedWindow) { mainWindow.loadURL('file://' + __dirname + '/browser/settings.html'); @@ -77,14 +77,6 @@ var createTemplate = function(mainWindow, config) { focusedWindow.webContents.send('activate-search-box'); } } - }, { - label: 'Search in Channel', - accelerator: 'Shift+CmdOrCtrl+S', - click: (item, focusedWindow) => { - if (focusedWindow) { - focusedWindow.webContents.send('activate-search-box-in-channel'); - } - } }] }); template.push({ @@ -229,9 +221,9 @@ var createTemplate = function(mainWindow, config) { template.push({ label: '&Help', submenu: [{ - label: `${app_name} Docs`, + label: `Learn More...`, click: function() { - electron.shell.openExternal('http://docs.mattermost.com'); + electron.shell.openExternal('https://docs.mattermost.com/help/apps/desktop-guide.html'); } }, { type: 'separator' diff --git a/src/package.json b/src/package.json index 53a2026b..07eea3f5 100644 --- a/src/package.json +++ b/src/package.json @@ -1,8 +1,8 @@ { - "name": "mattermost-desktop", + "name": "mattermost", "productName": "Mattermost", "desktopName": "Mattermost.desktop", - "version": "1.4.0", + "version": "3.4.0", "description": "Mattermost Desktop application for Windows, Mac and Linux", "main": "main.js", "author": {