Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(*): removing the use of deprecated isFunction #2274

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion demos/combo/load-on-demand.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
// Helper function to put an item data token to the selected item table utilizing a jQuery template
var selectedItemTemplate = '<tr><td class="propName">${propertyName}</td><td class="propValue">${propertyValue}</td></tr>';
function addItemValue(tableObject, item, itemProp) {
if (!($.isFunction(item[itemProp]))) {
if (typeof item[itemProp] !== "function") {
$($.ig.tmpl(selectedItemTemplate,
{
"propertyName": itemProp,
Expand Down
4 changes: 2 additions & 2 deletions demos/video-player/common-features.html
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@
else
$("#webMVideo").html($("#webMVideo").html() + '<span class="red">NO</span>');

$("#videoPlayer1").igVideoPlayer().bind({
$("#videoPlayer1").igVideoPlayer().on({
igvideoplayerplaying: function () {
playing = true;
$('#btnPlay span').html("Pause");
Expand Down Expand Up @@ -248,7 +248,7 @@
$("#videoPlayer1").igVideoPlayer("play");
});

$("#slider").slider({ value: 50 }).bind("slide", function (event, ui) {
$("#slider").slider({ value: 50 }).on("slide", function (event, ui) {
var value = ui.value;
$("#videoPlayer1").igVideoPlayer("option", "volume", value / 100);
});
Expand Down
28 changes: 14 additions & 14 deletions src/js/extensions/infragistics.ui.editors.knockout-extensions.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igtexteditorvaluechanged", function (event, args) {
editor.on("igtexteditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.newValue);
} else {
Expand All @@ -65,7 +65,7 @@
} else {

//In that case the model is updated on textChanged event
editor.bind("igtexteditortextchanged", function (event, args) {
editor.on("igtexteditortextchanged", function (event, args) {
// N.A. December 9th, 2016 #577 Don't update editor value, while typing. It is updated only on blur.
editor.data("igTextEditor")._doNotUpdate = true;
if (ko.isObservable(valueAccessor().value)) {
Expand All @@ -77,7 +77,7 @@
if (options.listItems !== undefined) {

//In that case the model is updated dropDownItemSelecting event
editor.bind("igtexteditordropdownitemselecting", function (event, args) {
editor.on("igtexteditordropdownitemselecting", function (event, args) {
if (ko.isObservable(valueAccessor().value) && args.item !== undefined) {
valueAccessor().value(args.item.innerText);
} else if (args.item !== undefined) {
Expand Down Expand Up @@ -115,7 +115,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igdatepickervaluechanged", function (event, args) {
editor.on("igdatepickervaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {

//T.P. #153479 Fix to use value instead of text, because editor sets date value and we should rely on that date, but not text.
Expand Down Expand Up @@ -187,7 +187,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igdateeditorvaluechanged", function (event, args) {
editor.on("igdateeditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {

//T.P. #153479 Fix to use value instead of text, because editor sets date value and we should rely on that date, but not text.
Expand Down Expand Up @@ -259,7 +259,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("ignumericeditorvaluechanged", function (event, args) {
editor.on("ignumericeditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.newValue);
} else {
Expand All @@ -269,7 +269,7 @@
} else {

//In that case the model is updated on textChanged event
editor.bind("ignumericeditortextchanged", function (event, args) {
editor.on("ignumericeditortextchanged", function (event, args) {
args.owner._processValueChanging(args.text);
editor.data("igNumericEditor")._doNotUpdate = true;
if (ko.isObservable(valueAccessor().value)) {
Expand Down Expand Up @@ -323,7 +323,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igcurrencyeditorvaluechanged", function (event, args) {
editor.on("igcurrencyeditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.newValue);
} else {
Expand All @@ -333,7 +333,7 @@
} else {

//In that case the model is updated on textChanged event
editor.bind("igcurrencyeditortextchanged", function (event, args) {
editor.on("igcurrencyeditortextchanged", function (event, args) {
args.owner._processValueChanging(args.text);
editor.data("igCurrencyEditor")._doNotUpdate = true;
if (ko.isObservable(valueAccessor().value)) {
Expand Down Expand Up @@ -385,7 +385,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igpercenteditorvaluechanged", function (event, args) {
editor.on("igpercenteditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.newValue);
} else {
Expand All @@ -395,7 +395,7 @@
} else {

//In that case the model is updated on textChanged event
editor.bind("igpercenteditortextchanged", function (event, args) {
editor.on("igpercenteditortextchanged", function (event, args) {
args.owner._processValueChanging(args.text);
editor.data("igPercentEditor")._doNotUpdate = true;
if (ko.isObservable(valueAccessor().value)) {
Expand Down Expand Up @@ -447,7 +447,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igmaskeditorvaluechanged", function (event, args) {
editor.on("igmaskeditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.newValue);
} else {
Expand Down Expand Up @@ -486,7 +486,7 @@
}

//In that case the model is updated on valueChanged event
editor.bind("igcheckboxeditorvaluechanged", function (event, args) {
editor.on("igcheckboxeditorvaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().checked)) {
valueAccessor().checked(args.newState);
} else {
Expand Down Expand Up @@ -528,7 +528,7 @@
if (options.updateMode.toLowerCase() === "onchange") {

//In that case the model is updated on valueChanged event
editor.bind("igtimepickervaluechanged", function (event, args) {
editor.on("igtimepickervaluechanged", function (event, args) {
if (ko.isObservable(valueAccessor().value)) {
valueAccessor().value(args.owner.value());
} else {
Expand Down
Loading
Loading