mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-12-08 20:48:48 +00:00
Fixed color-issue on entering a channel
This commit is contained in:
@@ -232,8 +232,8 @@ function setup_chat_listener(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
function setup_list_listener(){
|
function setup_list_listener(){
|
||||||
socket.on("channel", List.channel_function);
|
|
||||||
socket.on("color", Player.setBGimage);
|
socket.on("color", Player.setBGimage);
|
||||||
|
socket.on("channel", List.channel_function);
|
||||||
}
|
}
|
||||||
|
|
||||||
function setup_playlist_listener(){
|
function setup_playlist_listener(){
|
||||||
|
|||||||
@@ -618,7 +618,7 @@ var Player = {
|
|||||||
|
|
||||||
setBGimage: function(c){
|
setBGimage: function(c){
|
||||||
var color = c.color;
|
var color = c.color;
|
||||||
if(window.location.pathname != "/" && ((offline && c.only) || (!offline && !c.only))) {
|
if(window.location.pathname != "/" && ((offline && c.only) || (!offline && !c.only) || (!offline && c.only))) {
|
||||||
document.getElementById("main-container").style.backgroundColor = Helper.rgbToHsl(color,true);
|
document.getElementById("main-container").style.backgroundColor = Helper.rgbToHsl(color,true);
|
||||||
$("meta[name=theme-color]").attr("content", Helper.rgbToHex(color[0], color[1], color[2]));
|
$("meta[name=theme-color]").attr("content", Helper.rgbToHex(color[0], color[1], color[2]));
|
||||||
var new_color = Helper.rgbToHex(color[0], color[1], color[2]);
|
var new_color = Helper.rgbToHex(color[0], color[1], color[2]);
|
||||||
|
|||||||
Reference in New Issue
Block a user