Changed loading gif to a much smaller one

This commit is contained in:
Kasper Rynning-Tønnesen
2015-07-03 21:23:00 +02:00
parent acc4a80c6c
commit 1fafdbc77d
4 changed files with 14 additions and 7 deletions

View File

@@ -202,7 +202,7 @@
<div id="list-song" class="card left-align list-song"> <div id="list-song" class="card left-align list-song">
<span class="clickable vote-container" title="Vote!"> <span class="clickable vote-container" title="Vote!">
<a class="clickable center-align votebg"> <a class="clickable center-align votebg">
<span class="card-image cardbg list-image" style="background-image:url('/static/images/loading.gif');"></span> <span class="lazy card-image cardbg list-image" style="background-image:url('/static/images/loading.gif');"></span>
</a> </a>
<span class="card-content"> <span class="card-content">
<span class="flow-text truncate list-title"></span> <span class="flow-text truncate list-title"></span>

File diff suppressed because one or more lines are too long

Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -40,16 +40,23 @@ var List = {
$("#"+msg[1]).remove(); $("#"+msg[1]).remove();
full_playlist.splice(List.getIndexOfSong(msg[1]), 1); full_playlist.splice(List.getIndexOfSong(msg[1]), 1);
}, 305); }, 305);
document.getElementById('wrapper').scrollTop += 1;
document.getElementById('wrapper').scrollTop += -1;
}else if(msg[0] == "vote") }else if(msg[0] == "vote")
{ {
var index_of_song = List.getIndexOfSong(msg[1]); var index_of_song = List.getIndexOfSong(msg[1]);
var song_voted_on = full_playlist[index_of_song];
full_playlist[index_of_song].votes += 1; full_playlist[index_of_song].votes += 1;
full_playlist[index_of_song].added = msg[2]; full_playlist[index_of_song].added = msg[2];
full_playlist.sort(Helper.predicate({ full_playlist.sort(Helper.predicate({
name: 'votes', name: 'votes',
reverse: true reverse: true
}, 'added')); }, 'added'));
List.populate_list(full_playlist, false); $("#"+msg[1]).remove();
console.log(msg[1]);
List.insertAtIndex(List.getIndexOfSong(msg[1]), song_voted_on, false);
//List.populate_list(full_playlist, false);
}else if(msg[0] == "song_change") }else if(msg[0] == "song_change")
{ {
@@ -110,7 +117,7 @@ var List = {
}); });
if(window.mobilecheck()) $(".list-image").lazyload({}); if(window.mobilecheck()) $(".list-image").lazyload({});
else $(".list-image").lazyload({container: $("#wrapper")}); else $(".list-image").lazyload({container: $("#wrapper")}).removeClass("lazy");
$("#settings").css("visibility", "visible"); $("#settings").css("visibility", "visible");
$("#settings").css("opacity", "1"); $("#settings").css("opacity", "1");
$("#wrapper").css("opacity", "1"); $("#wrapper").css("opacity", "1");