From 272642966b3019cb09961f47de7b91c29e98f2b7 Mon Sep 17 00:00:00 2001 From: git-marijus Date: Sat, 13 Jul 2013 21:37:39 +0200 Subject: port like button to spin.js --- js/main.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'js') diff --git a/js/main.js b/js/main.js index 6a45c8f37..170062264 100644 --- a/js/main.js +++ b/js/main.js @@ -252,7 +252,7 @@ function NavUpdate() { if(liking) - $('.like-rotator').hide(); + $('.like-rotator').spin(false); if(! stopped) { @@ -423,7 +423,7 @@ function updateConvItems(mode,data) { }); } - $('.like-rotator').hide(); + $('.like-rotator').spin(false); if(commentBusy) { commentBusy = false; @@ -475,7 +475,7 @@ function updateConvItems(mode,data) { function liveUpdate() { - if((src == null) || (stopped) || (! profile_uid)) { $('.like-rotator').hide(); return; } + if((src == null) || (stopped) || (! profile_uid)) { $('.like-rotator').spin(false); return; } if(($('.comment-edit-text-full').length) || (in_progress)) { if(livetime) { clearTimeout(livetime); @@ -586,14 +586,14 @@ function updateConvItems(mode,data) { function dolike(ident,verb) { unpause(); - $('#like-rotator-' + ident.toString()).show(); + $('#like-rotator-' + ident.toString()).spin('tiny'); $.get('like/' + ident.toString() + '?verb=' + verb, NavUpdate ); liking = 1; } function dosubthread(ident) { unpause(); - $('#like-rotator-' + ident.toString()).show(); + $('#like-rotator-' + ident.toString()).spin('tiny'); $.get('subthread/' + ident.toString(), NavUpdate ); liking = 1; } @@ -601,7 +601,7 @@ function updateConvItems(mode,data) { function dostar(ident) { ident = ident.toString(); - $('#like-rotator-' + ident).show(); + $('#like-rotator-' + ident).spin('tiny'); $.get('starred/' + ident, function(data) { if(data.result == 1) { $('#starred-' + ident).addClass('starred'); @@ -615,7 +615,7 @@ function updateConvItems(mode,data) { $('#star-' + ident).removeClass('hidden'); $('#unstar-' + ident).addClass('hidden'); } - $('#like-rotator-' + ident).hide(); + $('#like-rotator-' + ident).spin(false); }); } -- cgit v1.2.3