From 431a4abd2563e8aa271549e5f18c523dcef4acaa Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 14 Dec 2011 14:17:48 -0800 Subject: name change stragglers, fix newmember links, liveupdate glitch --- js/main.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'js/main.js') diff --git a/js/main.js b/js/main.js index 65d05e58a..071acb777 100644 --- a/js/main.js +++ b/js/main.js @@ -257,11 +257,13 @@ $('.wall-item-outside-wrapper',data).each(function() { var ident = $(this).attr('id'); // If not on page 1, only add new conversation items to existing conversations on this page - if($('#' + ident).length == 0 && (profile_page == 1 || prev != 'live-' + src)) { - $('img',this).each(function() { - $(this).attr('src',$(this).attr('dst')); - }); - $('#' + prev).after($(this)); + if($('#' + ident).length == 0) { + if(profile_page == 1 || prev != 'live-' + src) { + $('img',this).each(function() { + $(this).attr('src',$(this).attr('dst')); + }); + $('#' + prev).after($(this)); + } } else { $('#' + ident + ' ' + '.wall-item-ago').replaceWith($(this).find('.wall-item-ago')); -- cgit v1.2.3 From 84fd2a1501e3cf2e7bf3c140e7f91ecfca2f7c7f Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 14 Dec 2011 15:51:13 -0800 Subject: live update glitches cont. --- js/main.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'js/main.js') diff --git a/js/main.js b/js/main.js index 071acb777..8421deb56 100644 --- a/js/main.js +++ b/js/main.js @@ -254,16 +254,14 @@ prev = 'live-' + src; - $('.wall-item-outside-wrapper',data).each(function() { + $('.wall-item-outside-wrapper.comment',data).each(function() { var ident = $(this).attr('id'); - // If not on page 1, only add new conversation items to existing conversations on this page + if($('#' + ident).length == 0) { - if(profile_page == 1 || prev != 'live-' + src) { $('img',this).each(function() { $(this).attr('src',$(this).attr('dst')); }); $('#' + prev).after($(this)); - } } else { $('#' + ident + ' ' + '.wall-item-ago').replaceWith($(this).find('.wall-item-ago')); -- cgit v1.2.3 From 9768adf719dffc59c1f2c7f0d4b2b932fcf9b142 Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 14 Dec 2011 16:43:37 -0800 Subject: testing --- js/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js/main.js') diff --git a/js/main.js b/js/main.js index 8421deb56..2c8a8fad1 100644 --- a/js/main.js +++ b/js/main.js @@ -254,10 +254,10 @@ prev = 'live-' + src; - $('.wall-item-outside-wrapper.comment',data).each(function() { + $('.wall-item-outside-wrapper',data).each(function() { var ident = $(this).attr('id'); - if($('#' + ident).length == 0) { + if($('#' + ident).length == 0 && prev != 'live-' + src) { $('img',this).each(function() { $(this).attr('src',$(this).attr('dst')); }); -- cgit v1.2.3 From 001e4023117b23c90a791eedd5c8026c48f45667 Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 14 Dec 2011 17:23:41 -0800 Subject: simplify live update --- js/main.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'js/main.js') diff --git a/js/main.js b/js/main.js index 2c8a8fad1..96c7fa642 100644 --- a/js/main.js +++ b/js/main.js @@ -241,18 +241,25 @@ $('.tread-wrapper',data).each(function() { var ident = $(this).attr('id'); + if($('#' + ident).length == 0 && profile_page == 1) { $('img',this).each(function() { $(this).attr('src',$(this).attr('dst')); }); $('#' + prev).after($(this)); } + else { + $('img',this).each(function() { + $(this).attr('src',$(this).attr('dst')); + }); + $('#' + ident).replaceWith($(this)); + } prev = ident; }); // reset vars for inserting individual items - prev = 'live-' + src; + /* prev = 'live-' + src; $('.wall-item-outside-wrapper',data).each(function() { var ident = $(this).attr('id'); @@ -276,7 +283,7 @@ } prev = ident; }); - + */ $('.like-rotator').hide(); if(commentBusy) { commentBusy = false; -- cgit v1.2.3