aboutsummaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorCa-Phun Ung <pazu2k@gmail.com>2009-01-31 10:40:55 +0000
committerCa-Phun Ung <pazu2k@gmail.com>2009-01-31 10:40:55 +0000
commit658a0f7f4097da160ef7117ad7e8c48494a242e3 (patch)
treecfb78d42423c3186b71a95f462d9df653f2a393d /ui
parentb388e6b8e1eeb73955ed4e39156f84181546888f (diff)
downloadjquery-ui-658a0f7f4097da160ef7117ad7e8c48494a242e3.tar.gz
jquery-ui-658a0f7f4097da160ef7117ad7e8c48494a242e3.zip
datepicker: #4003 - Inline datepicker and button panel.
Diffstat (limited to 'ui')
-rw-r--r--ui/ui.datepicker.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/ui/ui.datepicker.js b/ui/ui.datepicker.js
index c7705949d..9237de33f 100644
--- a/ui/ui.datepicker.js
+++ b/ui/ui.datepicker.js
@@ -1307,7 +1307,7 @@ $.extend(Datepicker.prototype, {
var gotoDate = (this._get(inst, 'gotoCurrent') && inst.currentDay ? currentDate : today);
currentText = (!navigationAsDateFormat ? currentText :
this.formatDate(currentText, gotoDate, this._getFormatConfig(inst)));
- var controls = '<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" onclick="jQuery.datepicker._hideDatepicker();">' + this._get(inst, 'closeText') + '</button>';
+ var controls = (!inst.inline ? '<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" onclick="jQuery.datepicker._hideDatepicker();">' + this._get(inst, 'closeText') + '</button>' : '');
var buttonPanel = (showButtonPanel) ? '<div class="ui-datepicker-buttonpane ui-widget-content">' + (isRTL ? controls : '') +
(this._isInRange(inst, gotoDate) ? '<button type="button" class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" onclick="jQuery.datepicker._gotoToday(\'#' + inst.id + '\');"' +
'>' + currentText + '</button>' : '') + (isRTL ? '' : controls) + '</div>' : '';
@@ -1405,8 +1405,7 @@ $.extend(Datepicker.prototype, {
}
html += group;
}
- html += (!inst.inline ? buttonPanel : '') +
- ($.browser.msie && parseInt($.browser.version,10) < 7 && !inst.inline ?
+ html += buttonPanel + ($.browser.msie && parseInt($.browser.version,10) < 7 && !inst.inline ?
'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>' : '');
inst._keyEvent = false;
return html;