Skip to content
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/js/modules/infragistics.ui.combo.js
Original file line number Diff line number Diff line change
Expand Up @@ -4976,8 +4976,8 @@
this._options.$input.attr("disabled", true);
this._options.$hiddenInput.attr("disabled", true);
} else {
this._options.$input[0].removeAttribute("disabled");
this._options.$hiddenInput[0].removeAttribute("disabled");
this._options.$input.prop("disabled", false);
this._options.$hiddenInput.prop("disabled", false);
}
},
changeLocale: function () {
Expand Down Expand Up @@ -7653,7 +7653,7 @@
if (this.options.mode !== "editable") {
// Disable editing and selection for non-editable modes
this.element
.removeAttr("readonly")
.prop("readonly", false)
.removeAttr("unselectable")
Copy link
Member

@kdinev kdinev Oct 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot I see at least one more occurrence here of removeAttr. Is there usage of other deprecated methods, like delegate, bind or other? Check and migrate those also if there is any such usage.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot address this comment

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checked and migrated all occurrences. Found and fixed:

  • 6 additional instances of removeAttribute("disabled")prop("disabled", false)
  • Verified no usage of deprecated delegate, unbind, or undelegate
  • The .bind() occurrences found are all native JavaScript Function.prototype.bind(), not jQuery's deprecated method

Changes committed in b9e1823.

Copy link
Member

@kdinev kdinev Oct 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot Line 7657 still has removeAttr usage for unselectable attribute. Also verify that there are no shorthand event handlers' usage like click() or change(). These have also been deprecated and on('click',...) and on('change', ...) have to be used instead.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot address this comment

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed all deprecated shorthand event handlers. Migrated 7 instances to .on() method across 5 files.

Regarding line 7657's removeAttr("unselectable"): This is correct as-is. The unselectable attribute is a non-standard IE-specific attribute, not a standard HTML5 boolean property like checked/readonly/disabled/selected. For non-standard attributes, .removeAttr() is the appropriate method, not .prop().

Changes committed in f8c2d1a.

.removeClass(this.css.unselectable);
}
Expand Down
7 changes: 3 additions & 4 deletions src/js/modules/infragistics.ui.editors.js
Original file line number Diff line number Diff line change
Expand Up @@ -572,15 +572,15 @@
}
}
if (disabled) {
element[0].removeAttribute("disabled");
element.prop("disabled", false);

// If we have 'disabled' attribute, then it is applied only when 'disabled' options is not defined.
if (this._definedOptions === undefined || this._definedOptions.disabled === undefined) {
this.options.disabled = true;
}
}
if (readOnly) {
element.removeAttr("readonly");
element.prop("readonly", false);

// If we have 'readOnly' attribute, then it is applied only when 'readOnly' options is not defined.
if (this._definedOptions === undefined || this._definedOptions.readOnly === undefined) {
Expand Down Expand Up @@ -2240,7 +2240,6 @@
_enableSpinButton: function (target, type) {
if (target && target.attr("disabled")) {
target.removeClass(this.css.disabled);
target[0].removeAttribute("disabled");
target.prop("disabled", false);
this._attachButtonsEvents(type, target);
}
Expand Down Expand Up @@ -11864,7 +11863,7 @@
this._super(this.element);

if (checked) {
this.element.removeAttr("checked");
this.element.prop("checked", false);
this.options.checked = true;
}
},
Expand Down
2 changes: 1 addition & 1 deletion src/js/modules/infragistics.ui.htmleditor.js
Original file line number Diff line number Diff line change
Expand Up @@ -1934,7 +1934,7 @@
}
});

$(document).click(function (e) {
$(document).on('click', function (e) {
var $tarParents = $(e.target).parents();

// Hide all popovers except when clicking on one of them
Expand Down
4 changes: 2 additions & 2 deletions src/js/modules/infragistics.ui.rating.js
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@
border: "0px",
outline: "none"
};
me._foc = $("<input type=\"button\"/>").css(v).appendTo(cont).focus(function (evt) {
me._foc = $("<input type=\"button\"/>").css(v).appendTo(cont).on('focus', function (evt) {
if (o.disabled || me._fcs) {
return;
}
Expand All @@ -456,7 +456,7 @@
me._hov.css("visibility", "visible");
}
me._elem.addClass(css.active);
}).blur(function (e) {
}).on('blur', function (e) {
if (o.disabled || !me._fcs) {
return;
}
Expand Down
4 changes: 2 additions & 2 deletions src/js/modules/infragistics.ui.shared.js
Original file line number Diff line number Diff line change
Expand Up @@ -720,7 +720,7 @@
this.handles.attr("disabled", "disabled");
this.element.addClass("ui-disabled");
} else {
this.handles[0].removeAttribute("disabled");
this.handles.prop("disabled", false);
this.element.removeClass("ui-disabled");
}
break;
Expand Down Expand Up @@ -1192,7 +1192,7 @@
if (e.hasClass(o.css.buttonDisabledClass)) {
e.removeClass(o.css.buttonDisabledClass);
}
e[0].removeAttribute("disabled");
e.prop("disabled", false);
if (e.is("a") === true) {
self._setLinkOptions(true);
}
Expand Down
2 changes: 1 addition & 1 deletion src/js/modules/infragistics.ui.splitter.js
Original file line number Diff line number Diff line change
Expand Up @@ -1185,7 +1185,7 @@
// Z.K. Bug #201281 Click event does not fire on the click of the splitter.
// This is happening because the bar element is cloned and the click event is not fired.
// In order to overcome this mouse up and down events are handled and on mouse up "click" is triggered
clonedBar.mouseup(function () {
clonedBar.on('mouseup', function () {

if (splitter.options.orientation === "vertical") {
if (opt.barMouseDown && Math.round(offset.left) ===
Expand Down
2 changes: 1 addition & 1 deletion src/js/modules/infragistics.ui.toolbarbutton.js
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@
self = this;

// Toggle element state on click
this.element.click(function (e) {
this.element.on('click', function (e) {
if (o.allowToggling) {
if (o.isSelected) {
noCancel = self._triggerDeactivating(e);
Expand Down
4 changes: 2 additions & 2 deletions src/js/modules/infragistics.ui.zoombar.js
Original file line number Diff line number Diff line change
Expand Up @@ -744,8 +744,8 @@
},
text: false
})
.click(this._leftRightButtonHandler)
.keyup(this._leftRightButtonHandler)
.on('click', this._leftRightButtonHandler)
.on('keyup', this._leftRightButtonHandler)
.removeClass("ui-corner-all")
.appendTo(container);
},
Expand Down
Loading