Esempio n. 1
0
        public MenuEngine(MainForm form, Menu rootMenu)
        {
            Form = form;
            Form.Execute += OnExecute;
            Form.ShortcutPressed += OnShortcutPressed;
            State = new MenuState(rootMenu);

            _textChangedTimer = new Timer();
            _textChangedTimer.Elapsed += (s, e) =>  OnTextChangedTimerElapsed();
            _textChangedTimer.Interval = 100;

            SearchBar.TextChanged += (s, e) => OnTextBoxTextChanged();
            SearchBar.KeyDown += OnTextBoxKeyDown;
            ListBox.SelectedIndexChanged += (s, a) => OnSelectedIndexChanged();

            ClearSearchBar();
        }
 public MenuEntryDeletion(MenuState state)
 {
     _state = state;
 }