Inheritance: System.EventArgs
Example #1
0
        private void ContextMenuActivatedHandler(object sender, ContextMenuEventArgs e)
        {
            ContextMenuStrip menu = CommandMenuBuilder.BuildContextMenu(e.Menu);

            if (_contextController != null)
                _contextController.Dispose();

            _contextController = new UICommandController();
            _contextController.BindCommandManager(_controller.CommandManager);
            _contextController.MapMenuItems(menu.Items);

            menu.Show(this, _pointerController.UntranslatePosition(new Point(e.Location.X, e.Location.Y)));
        }
Example #2
0
 protected virtual void OnContextMenuActivated(ContextMenuEventArgs e)
 {
     var ev = ContextMenuActivated;
     if (ev != null)
         ev(this, e);
 }