I need to be able to close the DropDownList on every page when the user scrolls the page. Some of my DropDownLists are input controls, some are divs, etc. Here is my solution; is there a better solution?
(MainContent is the scrolling div that surrounds all the content)
$(function() {
$('#main-content').on('scroll', function(e) {
$("*").each(function() {
var ddl = $(this).data("kendoDropDownList");
if (ddl) {
ddl.close();
}
});
});
(MainContent is the scrolling div that surrounds all the content)
$(function() {
$('#main-content').on('scroll', function(e) {
$("*").each(function() {
var ddl = $(this).data("kendoDropDownList");
if (ddl) {
ddl.close();
}
});
});