FSN#34665 meerdere kleine veranderingen

svn path=/Website/trunk/; revision=31346
This commit is contained in:
2016-11-03 11:03:17 +00:00
parent ed4d9b9809
commit b49d0839c4
2 changed files with 10 additions and 3 deletions

View File

@@ -424,7 +424,7 @@ function updateTableHeaders() {
floatingHeaderRow.css("width", $(this).css("width")-1);
var insideFrame = $(this).offset();
var outsideFrame = $(window.frameElement).offset();
var scrollTop = $(window.parent).scrollTop();
var scrollTop = $(window.parent).scrollTop() + $(window).scrollTop();
var offset = 0;
if (insideFrame) offset += insideFrame.top;
if (outsideFrame) offset += outsideFrame.top;
@@ -445,7 +445,7 @@ function updateTableHeaders() {
});
}
$(document).ready(function() {
function loadTableHeaders() {
$("table").each(function() {
$(this).wrap("<div class=\"divrstable\" style=\"position:relative\"></div>");
@@ -462,8 +462,15 @@ $(document).ready(function() {
clonedHeaderRow.css("opacity", "0.90");
originalHeaderRow.addClass("tableFloatingHeaderOriginal");
});
updateTableHeaders();
$(window.parent).scroll(updateTableHeaders);
$(window.parent).resize(updateTableHeaders);
};
$(function() {
// This should be executed lastly to ensure correct display of the table header.
setTimeout( loadTableHeaders, 250);
});

View File

@@ -75,7 +75,7 @@ var sorttable = {
}
// work through each column and calculate its type
var headrow = tableTheadTRs[0].querySelectorAll('td, th');
var headrow = tableTheadTRs[0].cells;
for (var i=0; i<headrow.length; i++) {
// manually override the type with a sorttable_type attribute