aboutsummaryrefslogtreecommitdiffstats
path: root/include/main.js
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2010-11-02 22:21:49 -0700
committerFriendika <info@friendika.com>2010-11-02 22:21:49 -0700
commit98a508532f0f3ea35748fa650aa3cad5e929e3de (patch)
treee65ec844ea7fcb83dfef7f9156ca971b7647c94c /include/main.js
parent07b78e9d1cc3785f41a76c2806efb871978927a3 (diff)
downloadvolse-hubzilla-98a508532f0f3ea35748fa650aa3cad5e929e3de.tar.gz
volse-hubzilla-98a508532f0f3ea35748fa650aa3cad5e929e3de.tar.bz2
volse-hubzilla-98a508532f0f3ea35748fa650aa3cad5e929e3de.zip
fix like/dislike refresh on photos/display items
Diffstat (limited to 'include/main.js')
-rw-r--r--include/main.js16
1 files changed, 15 insertions, 1 deletions
diff --git a/include/main.js b/include/main.js
index f0cb8571b..1b5553161 100644
--- a/include/main.js
+++ b/include/main.js
@@ -16,7 +16,7 @@
document.getElementById(theID).style.display = "none"
}
-
+
var src = null;
var prev = null;
var livetime = null;
@@ -24,6 +24,7 @@
var stopped = false;
var timer = null;
var pr = 0;
+ var liking = 0;
$(document).ready(function() {
$.ajaxSetup({cache: false});
@@ -49,6 +50,18 @@
if($('#live-network').length) { src = 'network'; liveUpdate(); }
if($('#live-profile').length) { src = 'profile'; liveUpdate(); }
+ if($('#live-display').length) {
+ if(liking) {
+ liking = 0;
+ window.location.href=window.location.href
+ }
+ }
+ if($('#live-photos').length) {
+ if(liking) {
+ liking = 0;
+ window.location.href=window.location.href
+ }
+ }
if(! stopped) {
$.get("ping",function(data) {
@@ -135,6 +148,7 @@
$.get('like/' + ident.toString() + '?verb=' + verb );
if(timer) clearTimeout(timer);
timer = setTimeout(NavUpdate,3000);
+ liking = 1;
}
function getPosition(e) {