Completed
Last Updated: 23 Apr 2014 12:56 by ADMIN
ADMIN
Plamen
Created on: 22 Jan 2013 04:13
Category:
Type: Bug Report
0
FIX. RadApplicationMenu - Left and Right keyboard navigation support should work like in MS MenuStrip in RightToLeft mode.
Steps to reproduce:
1) Add several menu items
2) Add a collection of child menu items for a specific radMenuItem
3) Set the RightToLeft property of the radApplicationMenu to true
4) Use the left and right keyboard navigation to access a child menu item

Expected Result: Left/Right keyboard navigation should work properly like in MS MenuStrip
Actual Result: Left/Right keyboard navigation works the same like in default mode (RightToLeft = false)

WORKAROUND:
class MyApplicationMenu : RadApplicationMenu
    {
        protected override RadDropDownButtonElement CreateButtonElement()
        {
            return new MyButtonElement();
        }

        public override string ThemeClassName
        {
            get
            {
                return typeof(RadApplicationMenu).FullName;
            }
            set
            {
                base.ThemeClassName = value;
            }
        }
    }

    class MyButtonElement : RadApplicationMenuButtonElement
    {
        protected override RadDropDownButtonPopup CreateDropDown()
        {
            return new MyApplicationMenuDropDown(this);
        }
    }

    class MyApplicationMenuDropDown : RadApplicationMenuDropDown
    {
        public MyApplicationMenuDropDown(RadApplicationMenuButtonElement button)
            : base(button)
        {

        }
        protected override bool ProcessLeftRightNavigationKey(bool isLeft)
        {
            return base.ProcessLeftRightNavigationKey(this.RightToLeft == System.Windows.Forms.RightToLeft.No ? isLeft : !isLeft);
        }
    }
0 comments