aboutsummaryrefslogtreecommitdiffstats
path: root/resources/lib/jquery.ui/jquery.ui.datepicker.js
diff options
context:
space:
mode:
authorAmir Sarabadani <Ladsgroup@gmail.com>2021-07-08 00:19:38 +0200
committerAmir Sarabadani <Ladsgroup@gmail.com>2021-07-10 00:32:16 +0200
commit9a53734df203d513695eba1602c9147d5f14049a (patch)
tree598025005f38c58fb8228145f1bcc1237b263ec3 /resources/lib/jquery.ui/jquery.ui.datepicker.js
parentcf8ec9bcae14f9127fe6e7989b0ced7a5b01949f (diff)
downloadmediawikicore-9a53734df203d513695eba1602c9147d5f14049a.tar.gz
mediawikicore-9a53734df203d513695eba1602c9147d5f14049a.zip
Patch jquery.ui to reduce deprecation warnings
Found them mostly by checking Wikibase repo. There are many more left. Bug: T280944 Change-Id: Icb54f847d32739674d74ab6cc5d55e9cbf738908
Diffstat (limited to 'resources/lib/jquery.ui/jquery.ui.datepicker.js')
-rw-r--r--resources/lib/jquery.ui/jquery.ui.datepicker.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/resources/lib/jquery.ui/jquery.ui.datepicker.js b/resources/lib/jquery.ui/jquery.ui.datepicker.js
index 15982fde5140..6c16ae6c2ae7 100644
--- a/resources/lib/jquery.ui/jquery.ui.datepicker.js
+++ b/resources/lib/jquery.ui/jquery.ui.datepicker.js
@@ -1772,17 +1772,17 @@ $.extend(Datepicker.prototype, {
/*
* Bind hover events for datepicker elements.
- * Done via delegate so the binding only occurs once in the lifetime of the parent div.
+ * Done via .on() so the binding only occurs once in the lifetime of the parent div.
* Global instActive, set by _updateDatepicker allows the handlers to find their way back to the active picker.
*/
function bindHover(dpDiv) {
var selector = 'button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a';
- return dpDiv.delegate(selector, 'mouseout', function() {
+ return dpDiv.on('mouseout', selector, function() {
$(this).removeClass('ui-state-hover');
if (this.className.indexOf('ui-datepicker-prev') != -1) $(this).removeClass('ui-datepicker-prev-hover');
if (this.className.indexOf('ui-datepicker-next') != -1) $(this).removeClass('ui-datepicker-next-hover');
})
- .delegate(selector, 'mouseover', function(){
+ .on('mouseover', selector, function(){
if (!$.datepicker._isDisabledDatepicker( instActive.inline ? dpDiv.parent()[0] : instActive.input[0])) {
$(this).parents('.ui-datepicker-calendar').find('a').removeClass('ui-state-hover');
$(this).addClass('ui-state-hover');