I'm using GWT table which is being generate dynamically with lots of columns but with out horizontal scroll bar and to get the scrollbar, we need wrapper with fixed width around the table, but GWT do create container but not adding any width to it.
To solve the problem, I'm calculating width of screen and adding it to the table wrapper, which is adding scroll bar to the table but working weirdly.
I'm using Live()
as it works for run time objects, also I can't use click event.
Here is the code:
$(function() {
var screenwidth = $(window).width();
$('body').live("mouseover", function() {
$('.scrollbar').css({
'width' : (screenwidth) - 40
});
$("body").unbind("mouseover");
});
});
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.