Demo for 1-pixel rounding problems
parent
6f9d8ebc9e
commit
0abc99b619
|
@ -87,7 +87,10 @@ TreeGrid.prototype.initStickyHeaders = function()
|
|||
this.sticky = true;
|
||||
this.stickyInit = this.header && this.header.length;
|
||||
if (this.stickyInit)
|
||||
{
|
||||
makeStickyHeaders(this.table);
|
||||
this.table.className += ' stickyheaders';
|
||||
}
|
||||
}
|
||||
|
||||
TreeGrid.prototype.setHeader = function(newHeader)
|
||||
|
@ -110,6 +113,7 @@ TreeGrid.prototype.setHeader = function(newHeader)
|
|||
if (!this.stickyInit)
|
||||
{
|
||||
makeStickyHeaders(this.table);
|
||||
this.table.className += ' stickyheaders';
|
||||
this.stickyInit = true;
|
||||
}
|
||||
else
|
||||
|
|
|
@ -11,7 +11,9 @@
|
|||
table, tr, td, th { box-sizing: border-box; background: white; }
|
||||
table { border-collapse: separate; border-spacing: 0px; }
|
||||
th, td { border-width: 0 1px 1px 0 !important; }
|
||||
.scroller { width: 500px; height: 400px; overflow: auto; }
|
||||
table td:nth-child(1) { width: 25%; }
|
||||
table.stickyheaders td:nth-child(2) { width: 25%; }
|
||||
.scroller { width: 100%; height: 400px; overflow: auto; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
|
Loading…
Reference in New Issue