From 00dfcbb462f6f2af8372296566f06c4cb5562aa0 Mon Sep 17 00:00:00 2001 From: lilia Date: Mon, 24 Aug 2015 09:10:48 -0700 Subject: [PATCH] Change websocket closed message --- js/chromium.js | 12 +++++++----- js/views/inbox_view.js | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/js/chromium.js b/js/chromium.js index e13db19f..2f6d7829 100644 --- a/js/chromium.js +++ b/js/chromium.js @@ -174,11 +174,13 @@ id = 'standalone-installer'; url = 'register.html'; } - extension.windows.open({ - id: id, - url: url, - bounds: { width: 800, height: 666 } - }); + if (!chrome.app.window.get(id)) { + extension.windows.open({ + id: id, + url: url, + bounds: { width: 800, height: 666 } + }); + } }; if (chrome.runtime.onInstalled) { diff --git a/js/views/inbox_view.js b/js/views/inbox_view.js index 2b6fbee2..7446e58c 100644 --- a/js/views/inbox_view.js +++ b/js/views/inbox_view.js @@ -39,7 +39,7 @@ break; case WebSocket.CLOSED: className = 'closed'; - message = 'Websocket closed'; + message = 'Disconnected'; break; } if (!this.$el.hasClass(className)) {