mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-10-29 18:00:23 +00:00
Fixed some disconnect errors, and styling of opacity element
This commit is contained in:
@@ -428,14 +428,15 @@ io.on('connection', function(socket){
|
||||
{
|
||||
if(in_list)
|
||||
{
|
||||
try
|
||||
{
|
||||
io.sockets.emit('chat,'+coll, rndName(guid) + " left");
|
||||
if(contains(lists[coll], guid))
|
||||
{
|
||||
console.log(guid + " left list " + coll);
|
||||
var index = lists[coll].indexOf(guid);
|
||||
lists[coll].splice(index, 1);
|
||||
io.sockets.emit(coll+",viewers", lists[coll].length);
|
||||
}catch(err){}
|
||||
io.sockets.emit('chat,'+coll, rndName(guid) + " left");
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -208,7 +208,7 @@ hide mdi-action-visibility mdi-action-visibility-off
|
||||
float: left;
|
||||
}
|
||||
|
||||
#chat-btn {
|
||||
#chat-btn i {
|
||||
-webkit-transition:opacity 1s;
|
||||
transition:opacity 1s;
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ document.getElementById("chat-btn").addEventListener("click", function(){
|
||||
console.log("clicked");
|
||||
$("#text-chat-input").focus();
|
||||
//$("#chat-btn").css("color", "white");
|
||||
$("#chat-btn").css("opacity", 1);
|
||||
$("#chat-btn i").css("opacity", 1);
|
||||
clearInterval(blink_interval);
|
||||
blink_interval_exists = false;
|
||||
});
|
||||
@@ -39,8 +39,8 @@ socket.on("chat,"+chan.toLowerCase(), function(data)
|
||||
|
||||
function chat_blink()
|
||||
{
|
||||
$("#chat-btn").css("opacity", 0.5);
|
||||
setTimeout(function(){$("#chat-btn").css("opacity", 1);}, 1000);
|
||||
$("#chat-btn i").css("opacity", 0.5);
|
||||
setTimeout(function(){$("#chat-btn i").css("opacity", 1);}, 1000);
|
||||
}
|
||||
|
||||
function hashCode(str) { // java String#hashCode
|
||||
|
||||
Reference in New Issue
Block a user