From 1ff65fecc648700e17f281a5cc50cdd163241c0a Mon Sep 17 00:00:00 2001 From: longqi Date: Mon, 7 Mar 2016 13:29:59 +0800 Subject: [PATCH] update GUI after ws close --- index.js | 7 +++++++ manifest.json | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index 71dbc21..1c6b8ee 100644 --- a/index.js +++ b/index.js @@ -54,6 +54,13 @@ new function() { var onClose = function() { console.log('CLOSED: ' + serverUrl.val()); ws = null; + connectionStatus.text('CLOSED'); + + serverUrl.removeAttr('disabled'); + connectButton.show(); + disconnectButton.hide(); + sendMessage.attr('disabled', 'disabled'); + sendButton.attr('disabled', 'disabled'); }; var onMessage = function(event) { diff --git a/manifest.json b/manifest.json index 382f999..c6822ab 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "name": "Simple WebSocket Client", "manifest_version": 2, - "version": "0.1.3", + "version": "0.1.4", "description": "Construct custom Web Socket requests and handle responses to directly test your Web Socket services.", "icons": { "16": "resources/icon_032.png",