Skip to content

Commit 85fb5ba

Browse files
author
Kendo Bot
committed
Sync with Kendo UI Professional
1 parent daafc10 commit 85fb5ba

File tree

4 files changed

+32
-3
lines changed

4 files changed

+32
-3
lines changed

docs/_config.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,10 +561,10 @@ navigation:
561561
baseurl: /kendo-ui
562562

563563
## The Kendo UI version used
564-
cdnVersion: "2018.2.516"
564+
cdnVersion: "2018.2.620"
565565

566566
## The MVC Core version used
567-
mvcCoreVersion: "2018.2.516"
567+
mvcCoreVersion: "2018.2.620"
568568

569569
## Progress NPM Registry
570570
registry_url: 'https://registry.npm.telerik.com/'

src/kendo.combobox.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -732,6 +732,8 @@ var __meta__ = { // jshint ignore:line
732732

733733
that._prev = input.value;
734734
});
735+
736+
that._toggleCloseVisibility();
735737
},
736738

737739
toggle: function(toggle) {

src/kendo.list.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,11 @@ var __meta__ = { // jshint ignore:line
645645
if (that._old === null || value === "") {
646646
that._valueBeforeCascade = that._old = value;
647647
} else {
648-
that._valueBeforeCascade = that._old = that.dataItem() ? that.dataItem()[that.options.dataValueField] || that.dataItem() : null;
648+
if (that.dataItem()) {
649+
that._valueBeforeCascade = that._old = that.options.dataValueField ? that.dataItem()[that.options.dataValueField] : that.dataItem();
650+
} else {
651+
that._valueBeforeCascade = that._old = null;
652+
}
649653
}
650654
that._oldIndex = index;
651655

@@ -897,6 +901,7 @@ var __meta__ = { // jshint ignore:line
897901
},
898902

899903
_triggerChange: function() {
904+
debugger;
900905
if (this._valueBeforeCascade !== this.value()) {
901906
this.trigger(CHANGE);
902907
}

tests/dropdownlist/events.js

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,28 @@
7474
});
7575
});
7676

77+
test("change event is raised once when value is 0 and widget is blurred", 1, function() {
78+
var dropdownlist = new DropDownList(input, {
79+
dataTextField: "text",
80+
dataValueField: "value",
81+
dataSource: [
82+
{ text: "Black", value: 0 },
83+
{ text: "Orange", value: 1 },
84+
{ text: "Grey", value: 2 }
85+
],
86+
index: 1,
87+
change: function() {
88+
ok(true);
89+
}
90+
});
91+
92+
dropdownlist.open();
93+
dropdownlist.ul.find("li:first").click();
94+
95+
dropdownlist._change();
96+
dropdownlist._change();
97+
});
98+
7799
test("_change raises the change event if value has changed", function() {
78100
var changeWasCalled = false, dropdownlist = new DropDownList(input, {
79101
dataSource: ["foo", "bar"],

0 commit comments

Comments
 (0)