Skip to content

Commit

Permalink
reverting the fix for angular-ui#1221
Browse files Browse the repository at this point in the history
The fix for this issue seems to have introduced various other issues.
I've noticed that the column headers sometimes get out of alignment with
their corresponding columns, especially when a grid contains pinned
columns. This should also fix angular-ui#3044.
  • Loading branch information
jjkovacs committed Apr 14, 2015
1 parent b494fca commit 2d2dcaa
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/services/DomUtilityService.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,12 +126,8 @@
for (var i = 0; i < cols.length; i++) {
var col = cols[i];
if (col.visible !== false) {
var rightPad = 0;
if ((i === cols.length - 1) && (sumWidth + col.width < grid.elementDims.rootMaxW)) {
rightPad = grid.elementDims.rootMaxW - sumWidth - col.width;
}
css += "." + gridId + " .col" + i + " { width: " + (col.width + rightPad) + "px; left: " + sumWidth + "px; height: " + rowHeight + "px }" +
"." + gridId + " .colt" + i + " { width: " + (col.width + rightPad) + "px; }";
css += "." + gridId + " .col" + i + " { width: " + col.width + "px; left: " + sumWidth + "px; height: " + rowHeight + "px }" +
"." + gridId + " .colt" + i + " { width: " + col.width + "px; }";
sumWidth += col.width;
}
}
Expand Down

0 comments on commit 2d2dcaa

Please sign in to comment.