From ad3669d8bc0dfa4bf7903b90ec322c7c5366670c Mon Sep 17 00:00:00 2001 From: Jonas Herzig Date: Mon, 8 Oct 2018 19:21:48 +0200 Subject: [PATCH] Add config options to remove fields from Connect dialog --- app/config.js | 8 ++++++++ app/index.html | 10 +++++----- app/index.js | 5 +++-- 3 files changed, 16 insertions(+), 7 deletions(-) diff --git a/app/config.js b/app/config.js index 1db7a02..23b8fec 100644 --- a/app/config.js +++ b/app/config.js @@ -3,6 +3,14 @@ // configuration options. Use the [config.local.js] file instead! window.mumbleWebConfig = { + // Which fields to show on the Connect to Server dialog + 'connectDialog': { + 'address': true, + 'port': true, + 'token': true, + 'username': true, + 'password': true + }, // Default values (can be changed by passing a query parameter of the same name) 'defaults': { // Connect Dialog diff --git a/app/index.html b/app/index.html index 94321be..5c346b4 100644 --- a/app/index.html +++ b/app/index.html @@ -31,23 +31,23 @@
- + - + - + - + - + diff --git a/app/index.js b/app/index.js index a3dd75b..e25c748 100644 --- a/app/index.js +++ b/app/index.js @@ -260,7 +260,8 @@ class Settings { } class GlobalBindings { - constructor () { + constructor (config) { + this.config = config this.settings = new Settings() this.connector = new WorkerBasedMumbleConnector() this.client = null @@ -860,7 +861,7 @@ class GlobalBindings { } } } -var ui = new GlobalBindings() +var ui = new GlobalBindings(window.mumbleWebConfig) // Used only for debugging window.mumbleUi = ui
Address
Port
Token
Username
Password