mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-02-01 03:12:42 +01:00
fix issue with load of showuserandchat
This commit is contained in:
parent
af7cd91a82
commit
f3e5682a0f
1 changed files with 3 additions and 1 deletions
|
@ -22,6 +22,7 @@ var hooks = require('./pluginfw/hooks');
|
||||||
var chat = (function()
|
var chat = (function()
|
||||||
{
|
{
|
||||||
var isStuck = false;
|
var isStuck = false;
|
||||||
|
var userAndChat = false;
|
||||||
var gotInitialMessages = false;
|
var gotInitialMessages = false;
|
||||||
var historyPointer = 0;
|
var historyPointer = 0;
|
||||||
var chatMentions = 0;
|
var chatMentions = 0;
|
||||||
|
@ -56,13 +57,14 @@ var chat = (function()
|
||||||
},
|
},
|
||||||
chatAndUsers: function(fromInitialCall)
|
chatAndUsers: function(fromInitialCall)
|
||||||
{
|
{
|
||||||
if(fromInitialCall || $('#options-chatandusers').prop('checked')){
|
if(!userAndChat || fromInitialCall){
|
||||||
padcookie.setPref("chatAndUsers", true);
|
padcookie.setPref("chatAndUsers", true);
|
||||||
chat.stickToScreen(true);
|
chat.stickToScreen(true);
|
||||||
$('#options-stickychat').prop('checked', true)
|
$('#options-stickychat').prop('checked', true)
|
||||||
$('#options-stickychat').prop("disabled", "disabled");
|
$('#options-stickychat').prop("disabled", "disabled");
|
||||||
$('#users').addClass("chatAndUsers");
|
$('#users').addClass("chatAndUsers");
|
||||||
$("#chatbox").addClass("chatAndUsersChat");
|
$("#chatbox").addClass("chatAndUsersChat");
|
||||||
|
userAndChat = true;
|
||||||
}else{
|
}else{
|
||||||
padcookie.setPref("chatAndUsers", false);
|
padcookie.setPref("chatAndUsers", false);
|
||||||
$('#options-stickychat').prop("disabled", false);
|
$('#options-stickychat').prop("disabled", false);
|
||||||
|
|
Loading…
Reference in a new issue