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

Second level of context menu doesn't display correctly sometimes

1 Answer 89 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Roman
Top achievements
Rank 1
Roman asked on 15 Mar 2012, 04:54 PM
I have context menu with a lot of items in second level(>50).
I set RadMenuItem.GroupSettings.Height = 200px for all first level items.

Steps for reproduce:

Open second level menu items, click anywhere to close menu.
Do the same second time and you can see that second menu level items display incorrect. the appear under the top of window(few items are not visible).

How can i know when menu items will display not in bounds of window ?
How can i control position of second menu level items?

1 Answer, 1 is accepted

Sort by
0
Paul
Top achievements
Rank 1
answered on 11 Apr 2012, 10:51 AM
After much searching I couldn't find a reason or official solution for this "quirk" but did find a workaround which I hope helps others who come across this issue. On my RadMenu I set the OnClientItemOpened property = "OnClientItemOpened" and then that function is as follows:

function OnClientItemOpened(sender, args) {
    var item = args.get_item();
    item._positionChildContainerBasic();
    if (item._getScrollWrapElement()) item._updateScrollSize();
}



Tags
Menu
Asked by
Roman
Top achievements
Rank 1
Answers by
Paul
Top achievements
Rank 1
Share this question
or