From fbeefaf78826a130d3d7ffdc735d6c8b7d8744fd Mon Sep 17 00:00:00 2001 From: nathangray Date: Wed, 29 Mar 2017 08:32:43 -0600 Subject: [PATCH] Calendar - Fix planner view in Firefox sometimes had headers mis-aligned with columns Deferred loading caused scrollbar width calculation issues. --- calendar/js/et2_widget_planner.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/calendar/js/et2_widget_planner.js b/calendar/js/et2_widget_planner.js index bb98ed049b..c202ed1e19 100644 --- a/calendar/js/et2_widget_planner.js +++ b/calendar/js/et2_widget_planner.js @@ -1924,6 +1924,14 @@ var et2_calendar_planner = (function(){ "use strict"; return et2_calendar_view.e // Add 1 to keep the scrollbar, otherwise we need to recalculate the // header widths too. this.grid.height(this.rows[0].scrollHeight+1); + + // Adjust header if there's a scrollbar - Firefox needs this re-calculated, + // otherwise the header will be missing the margin space for the scrollbar + // in some cases + if(this.rows.children().last().length) + { + this.gridHeader.css('margin-right', (this.rows.width() - this.rows.children().last().width()) + 'px'); + } }, /**