From a3df6dd8a8e363a276392acd7744f7db1e75eb61 Mon Sep 17 00:00:00 2001 From: Felix Nagel Date: Sat, 11 Apr 2015 00:04:33 +0200 Subject: [PATCH] Calendar: Add comment in _needsRefresh method --- ui/calendar.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/calendar.js b/ui/calendar.js index 05d4c229b..40884c283 100644 --- a/ui/calendar.js +++ b/ui/calendar.js @@ -142,6 +142,9 @@ return $.widget( "ui.calendar", { _needsRefresh: function() { if ( this.date.month() !== this.viewDate.month() || this.date.year() !== this.viewDate.year() ) { + + // Check if the needed day is already present in our grid due + // to eachDay option changes (eg. other-months demo) return !this.grid.find( this._sanitizeSelector( "#" + this._getDayId( this.date ) ) ).length; -- 2.39.5