aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/main.js
diff options
context:
space:
mode:
Diffstat (limited to 'view/js/main.js')
-rw-r--r--view/js/main.js20
1 files changed, 4 insertions, 16 deletions
diff --git a/view/js/main.js b/view/js/main.js
index 9b5c1b1b2..8939f4a09 100644
--- a/view/js/main.js
+++ b/view/js/main.js
@@ -207,6 +207,7 @@
var loadingPage = true;
var pageHasMoreContent = true;
var updateCountsOnly = false;
+ var divmore_height = 400;
$(function() {
$.ajaxSetup({cache: false});
@@ -591,27 +592,14 @@ function updateConvItems(mode,data) {
function collapseHeight() {
- var isListMode = false;
- $(".wall-item-listbody").each(function() {
- isListMode = true;
- if($(this).height() > 210) {
+ $(".wall-item-body").each(function() {
+ if($(this).height() > divmore_height + 10) {
if(! $(this).hasClass('divmore')) {
- $(this).divgrow({ initialHeight: 200, moreText: aStr['divgrowmore'], lessText: aStr['divgrowless'], showBrackets: false });
+ $(this).divgrow({ initialHeight: divmore_height, moreText: aStr['divgrowmore'], lessText: aStr['divgrowless'], showBrackets: false });
$(this).addClass('divmore');
}
}
});
-
- $(".wall-item-body").each(function() {
- if(! isListMode) {
- if($(this).height() > 410) {
- if(! $(this).hasClass('divmore')) {
- $(this).divgrow({ initialHeight: 400, moreText: aStr['divgrowmore'], lessText: aStr['divgrowless'], showBrackets: false });
- $(this).addClass('divmore');
- }
- }
- }
- });
}
function liveUpdate() {