Example #1
0
        public MenuItem()
        {
            this.DefaultStyleKey = typeof(MenuItem);
            this.Loaded         += new RoutedEventHandler(MenuItem_Loaded);
            if (Items == null)
            {
                Items = new ObservableCollection <MenuItem>();
            }
            if (string.IsNullOrEmpty(MenuText))
            {
                MenuText = "Default";
            }

            MouseOverTimer       = new DispatcherTimer();
            MouseOverTimer.Tick += (se, ev) =>
            {
                MouseOverTimer.Stop();
                ShowDropDown();
            };

            isNested = false;

            parentMenuBarItem = null;
            parentMenuItem    = null;
        }
Example #2
0
        public MenuItem()
        {
            this.DefaultStyleKey = typeof(MenuItem);
            this.Loaded += new RoutedEventHandler(MenuItem_Loaded);
            if (items == null)
                items = new ObservableCollection<MenuItem>();
            if (string.IsNullOrEmpty(MenuText))
                MenuText = "Default";

            isNested = false;

            parentMenuBarItem = null;
            parentMenuItem = null;
        }
Example #3
0
        public MenuItem()
        {
            this.DefaultStyleKey = typeof(MenuItem);
            this.Loaded         += new RoutedEventHandler(MenuItem_Loaded);
            if (items == null)
            {
                items = new ObservableCollection <MenuItem>();
            }
            if (string.IsNullOrEmpty(MenuText))
            {
                MenuText = "Default";
            }

            isNested = false;

            parentMenuBarItem = null;
            parentMenuItem    = null;
        }
Example #4
0
        public MenuItem()
        {
            this.DefaultStyleKey = typeof(MenuItem);
            this.Loaded += new RoutedEventHandler(MenuItem_Loaded);
            if (Items == null)
                Items = new ObservableCollection<MenuItem>();
            if (string.IsNullOrEmpty(MenuText))
                MenuText = "Default";

            MouseOverTimer = new DispatcherTimer();
            MouseOverTimer.Tick += (se, ev) =>
            {
                MouseOverTimer.Stop();
                ShowDropDown();
            };

            isNested = false;

            parentMenuBarItem = null;
            parentMenuItem = null;
        }