mirror of
https://codeberg.org/emersion/gamja
synced 2025-03-12 23:43:42 +01:00
Add autoconnect to config.json
This commit is contained in:
parent
312a3f812e
commit
47b12cc5d9
@ -90,6 +90,9 @@ gamja default settings can be set using a `config.json` file at the root:
|
|||||||
// require it, and "disabled" to never ask for a password. Defaults to
|
// require it, and "disabled" to never ask for a password. Defaults to
|
||||||
// "optional".
|
// "optional".
|
||||||
"auth": "optional",
|
"auth": "optional",
|
||||||
|
// Don't display the login UI, immediately connect to the server
|
||||||
|
// (boolean).
|
||||||
|
"autoconnect": true,
|
||||||
// Interval in seconds to send PING commands (number). Set to 0 to
|
// Interval in seconds to send PING commands (number). Set to 0 to
|
||||||
// disable. Enabling PINGs can have an impact on client power usage and
|
// disable. Enabling PINGs can have an impact on client power usage and
|
||||||
// should only be enabled if necessary.
|
// should only be enabled if necessary.
|
||||||
|
@ -201,6 +201,9 @@ export default class App extends Component {
|
|||||||
} else if (typeof config.server.autojoin === "string") {
|
} else if (typeof config.server.autojoin === "string") {
|
||||||
connectParams.autojoin = [config.server.autojoin];
|
connectParams.autojoin = [config.server.autojoin];
|
||||||
}
|
}
|
||||||
|
if (typeof config.server.autoconnect === "boolean") {
|
||||||
|
connectParams.autoconnect = config.server.autoconnect;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let autoconnect = store.autoconnect.load();
|
let autoconnect = store.autoconnect.load();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user