Clean up
This commit is contained in:
parent
308818fd74
commit
c623019fe3
1 changed files with 3 additions and 6 deletions
|
|
@ -85,9 +85,9 @@ const systemWindow = document.getElementById("chat-system-box") as HTMLDivElemen
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let anti_flicker_control = false;
|
|
||||||
|
|
||||||
function chatKeyToggle() {
|
function chatKeyToggle() {
|
||||||
|
let anti_flicker_control = false;
|
||||||
const chat_toggle_key = 'f1';
|
const chat_toggle_key = 'f1';
|
||||||
document.addEventListener("keydown", (event) => {
|
document.addEventListener("keydown", (event) => {
|
||||||
if (event.repeat && keysPressed[chat_toggle_key] === true) {
|
if (event.repeat && keysPressed[chat_toggle_key] === true) {
|
||||||
|
|
@ -550,10 +550,7 @@ document.addEventListener("ft:userChange", (user) => {
|
||||||
window.__state.chatSock = undefined;
|
window.__state.chatSock = undefined;
|
||||||
if (newUser === null) {
|
if (newUser === null) {
|
||||||
quitChat();
|
quitChat();
|
||||||
// logged out
|
|
||||||
// hide chat button
|
|
||||||
} else {
|
} else {
|
||||||
// user has changed
|
|
||||||
initChatSocket();
|
initChatSocket();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue