From d7939faae293b82d24eee21d613fe56309d6988c Mon Sep 17 00:00:00 2001 From: Felix Nagel Date: Sat, 16 Apr 2016 17:20:58 +0200 Subject: [PATCH] Calendar: Add icons option support --- tests/unit/calendar/common.js | 4 ++++ ui/widgets/calendar.js | 29 +++++++++++++++++------------ 2 files changed, 21 insertions(+), 12 deletions(-) diff --git a/tests/unit/calendar/common.js b/tests/unit/calendar/common.js index 586c505f8..b6807ec84 100644 --- a/tests/unit/calendar/common.js +++ b/tests/unit/calendar/common.js @@ -17,6 +17,10 @@ common.testWidget( "calendar", { disabled: false, dateFormat: { date: "short" }, eachDay: $.noop, + icons: { + prevButton: "ui-icon-circle-triangle-w", + nextButton: "ui-icon-circle-triangle-e" + }, labels: { "datePickerRole": "date picker", "nextText": "Next", diff --git a/ui/widgets/calendar.js b/ui/widgets/calendar.js index f84c4d1cf..4c9a03545 100644 --- a/ui/widgets/calendar.js +++ b/ui/widgets/calendar.js @@ -54,6 +54,10 @@ return $.widget( "ui.calendar", { }, dateFormat: { date: "short" }, eachDay: $.noop, + icons: { + prevButton: "ui-icon-circle-triangle-w", + nextButton: "ui-icon-circle-triangle-e" + }, labels: { "datePickerRole": "date picker", "nextText": "Next", @@ -309,20 +313,21 @@ return $.widget( "ui.calendar", { _buildHeaderButtons: function() { var buttons = $( "
" ); - this.prevButton = $( "