diff options
author | Aaron LI <aaronly.me@outlook.com> | 2016-11-28 14:16:34 +0800 |
---|---|---|
committer | Aaron LI <aaronly.me@outlook.com> | 2016-11-28 14:16:34 +0800 |
commit | f556ea8a2c4409b170775c7ef46a8a5976980ee8 (patch) | |
tree | f653a4069a63760c98ec5096fc1a6f1a0910580d /fg21sim/webui/static/js/websocket.js | |
parent | f766c58aabfa35678f2a0a1e5163ff8b3c6129de (diff) | |
download | fg21sim-f556ea8a2c4409b170775c7ef46a8a5976980ee8.tar.bz2 |
webui: Use the same "#modal-box" and the "showModal()" function
Diffstat (limited to 'fg21sim/webui/static/js/websocket.js')
-rw-r--r-- | fg21sim/webui/static/js/websocket.js | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/fg21sim/webui/static/js/websocket.js b/fg21sim/webui/static/js/websocket.js index 0480716..12c89a4 100644 --- a/fg21sim/webui/static/js/websocket.js +++ b/fg21sim/webui/static/js/websocket.js @@ -200,10 +200,7 @@ $(document).ready(function () { // WebSocket NOT supported console.warn("Oops, WebSocket is NOT supported!"); updateWSStatus("unsupported"); - // Create a modal box and show a warning - var modalBox = $("<div>").addClass("modal").attr("id", "modal-websocket"); - $("body").append(modalBox); - showModal(modalBox, { + showModal({ icon: "warning", title: "WebSocket is NOT supported by the browser!", contents: ("The <strong>necessary functionalities</strong> do NOT " + |