This is a migrated thread and some comments may be shown as answers.

How to Make Column Menu Sticky?

2 Answers 99 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Scott
Top achievements
Rank 1
Scott asked on 11 Feb 2013, 05:14 PM
We use the Kendo Grid Column Menu but would like the “Columns” submenu to not disappear when the mouse leaves the submenu.  So we want the submenu to be “sticky.”  Is there a way to do that?  Also, what event triggers the submenu to disappears and where is it done?  Please see image below.

2 Answers, 1 is accepted

Sort by
0
Dimiter Madjarov
Telerik team
answered on 12 Feb 2013, 04:24 PM
Hi Scott,

Each of the column menus in the Grid is actually a Kendo Menu. To achieve this behavior you could set to true the openOnClick and closeOnClick options on each of them using the setOptions method. 

 E.g.

$(document).ready(function () {
    var menus = $(".k-column-menu .k-menu");
    for (var i = 0; i < menus.length; i++) {
        var current = $(menus[i]).data("kendoMenu");
        current.setOptions({ openOnClick: true, closeOnClick: true });
    }
});

Please let me know if this solution works in your scenario.


Regards,
Dimiter Madjarov
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Thuy
Top achievements
Rank 1
answered on 12 Feb 2013, 07:11 PM
Thank you Dimeter.  That took care of the problem that we were having!
Tags
Grid
Asked by
Scott
Top achievements
Rank 1
Answers by
Dimiter Madjarov
Telerik team
Thuy
Top achievements
Rank 1
Share this question
or