Skip to content

Desktop v3

Mike Bartlett requested to merge v3-nwjs into master

Created by: MadLittleMods

  • Update docs to add more detail on how to build
  • Upgrade to nw.js v0.12.3
  • Fix focus issue on initial load with mac. Mac apps do not have focus when they start up
  • Update notifier.js so that it no longer plays the native sound, fixes https://github.com/gitterHQ/desktop/issues/99
  • Add avatars to notifications for Windows
  • I assume this covers as the official release of the nw.js version of the mac app: https://github.com/gitterHQ/desktop/issues/47
  • Generalize windows desktop build, see ./windows/README.md and ./windows/build.js. ./windows/build.bat has also gotten some love but is deprecated and is only there until we are confident and settled with the node script.
  • Remove startup option from Windows installer because it did not obey whatever you set it to(always enabled launch at startup): https://github.com/gitterHQ/desktop/issues/106
  • Add context menu option to toggle launch on startup (tested on Mac and Windows): https://github.com/gitterHQ/desktop/issues/45
  • Add "Show in Menu bar" toggle (this option existed previously but didn't do anything)
  • Add gulp check-path-safety-for-windows to build flow so you don't get unexpected blank screen when developing on Windows
  • Update auto-update params/logic so we can actually use cli params outside of the autoupdate process.
    • --update-url: Specify custom URL to check and download updates from
    • --passthrough-remote-debugging-port: So you can debug the new instances we pop throughout the update process
  • Update auto-update logic to check on start and every 24-hours after that
  • Add packages -> osx package.json manifest check entry to play more nicely with our platform checks.

Notifications

Windows 10

Windows 8.1

Mac OSX

Ubuntu 14.04.03


Debug nw.js from another PC.

Route localhost:9222 to the external reachable local network. Here are instructions for setting it up on Mac: https://github.com/nwjs/nw.js/issues/1444#issuecomment-179926199

localhost:9222 -> 192.168.0.58:9222

Then start up the nw.js app:

npm start -- --remote-debugging-port=9222

Visit 192.168.0.58:9222 on the other machine

These parameters also work on a final build.

Windows

"C:\Users\YOUR_USER\AppData\Local\Programs\Gitter\Gitter.exe" --remote-debugging-port=9222 --passthrough-remote-debugging-port=9222

OSX

open /Applications/Gitter.app --args --remote-debugging-port=9222 --passthrough-remote-debugging-port=9222

Windows 10 notifications

Just to dump my knowledge here while it's fresh:

The new notifications in Windows 10 are "toast" notifications. They can be setup by creating a .lnkalso know as "shortcut" in one of the Start menu folders such as "C:\Users\MLM\AppData\Roaming\Microsoft\Windows\Start Menu\Programs".

With nw.js you can use var gui = require('nw.gui'); gui.App.createShortcut(...);_(read more here)_ but we decided to go with node-notifier because it has a sound: false option also know as the "quiet" or "silent" option in their internals. Which can stop the native Windows 10 notification sound from chiming in.

Users can manually manage their notification preferences on a individual basis by opening "Notifications & action settings". http://i.imgur.com/DjNB2oL.png - Because we are using node-notifier the entry is called toast which is the vendor specific exe(find the source here) they use to make the notifications. This does mean that the entry is shared across all apps that use node-notifier but the user shouldn't be touching it in the settings anyway because apps customize their own behaviour (hopefully conscientiously)

Edited by 🤖 GitLab Bot 🤖

Merge request reports