Hello,
I use the following Code to create a Kendo window dynamical to load a partial view - after closing the window I call the destroy method
to remove the window and it Content from the DOM.
$(
"<div id='win"
+ name +
"' />"
).kendoWindow({
title: stitle,
actions: [
"Close"
],
draggable:
false
,
resizable:
false
,
//appendTo: "#containerTest",
modal:
true
,
animation: {
open: {
effects:
"slideIn:left"
,
duration: 500
},
close: {
effects:
"slideIn:left"
,
reverse:
true
,
duration: 500
}
},
visible:
false
,
pinned:
false
,
content: { url: surl, iframe: iframe },
close:
function
(e) {
},
deactivate:
function
(e) {
this
.destroy();
}
});
var
window = $(windowname).data(
"kendoWindow"
);
window.wrapper.addClass(
"gpdb-sidebar-window"
);
window.open();
But there is a Performance Problem if I open the window in a view with a Kendo grid with more then 500 rows - it seems that to use the destroy() in the deactivate Event of the window becomes slower and slower the more rows in the grid exists...
I have attached a Picture from the Chrome performance analyser - it seems there is a "Recalculate Style" in Kendo.all.js which is called often...
robert