[Mapbender-commits] r6024 - trunk/mapbender/http/javascripts
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Mon Apr 26 05:05:01 EDT 2010
Author: christoph
Date: 2010-04-26 05:05:01 -0400 (Mon, 26 Apr 2010)
New Revision: 6024
Modified:
trunk/mapbender/http/javascripts/mod_tab_expandable.js
Log:
Modified: trunk/mapbender/http/javascripts/mod_tab_expandable.js
===================================================================
--- trunk/mapbender/http/javascripts/mod_tab_expandable.js 2010-04-26 09:04:30 UTC (rev 6023)
+++ trunk/mapbender/http/javascripts/mod_tab_expandable.js 2010-04-26 09:05:01 UTC (rev 6024)
@@ -273,10 +273,8 @@
return coords.join(",");
};
- var getWindowHeight = function () {
- var dh = $(document).height();
- var wh = $(window).height();
- return wh > dh ? wh : dh;
+ var getDocumentHeight = function () {
+ return $(document).height();
};
/**
@@ -286,7 +284,7 @@
* @param {String} openOrClose a string with the values "open" or "close".
*/
this.animate = function(openOrClose){
- var height = getWindowHeight() - this.get(0).top();
+ var height = getDocumentHeight() - this.get(0).top();
for (var i = 0; i < this.count(); i++) {
@@ -432,8 +430,8 @@
activeTab.top = ((newpos + 1) + obj.tab_height) + "px";
activeTab.left = (tabLeftOffset) + "px";
activeTab.width = tabWidth;
- var height = getWindowHeight() - that.get(0).top();
- var diff = height - that.count() * tabHeight - 2;
+ var height = getDocumentHeight() - that.get(0).top();
+ var diff = height - that.count() * tabHeight - 4;
activeTab.height = diff + "px";
//(parseInt(that.get(index).height) - 2) - obj.tab_height;
}
@@ -444,7 +442,7 @@
obj.top = (newpos + 1) + "px";
obj.left = (tabLeftOffset) + "px";
obj.width = tabWidth;
- var height = getWindowHeight() - that.get(0).top();
+ var height = getDocumentHeight() - that.get(0).top();
var diff = height - that.count() * tabHeight - 4;
obj.height = diff + "px";
obj.visibility = 'visible';
@@ -526,8 +524,8 @@
styleObj.addClass("verticalTabs", tabStyle);
var resizeTabs = function(e){
- var height = getWindowHeight() - that.get(0).top();
- var diff = height - that.count() * tabHeight - 2;
+ var height = $(window).scrollTop() + $(window).height() - that.get(0).top();
+ var diff = height - that.count() * tabHeight - 4;
var indexOfOpeningTab = getIndexById(activeTabId);
var node = that.get(indexOfOpeningTab);
if (node === undefined) {
More information about the Mapbender_commits
mailing list