예제 #1
0
        private void contextRadDropDownButton_MouseDown(object sender, MouseEventArgs e)
        {
            DockWindow active = this.radDock1.DocumentManager.ActiveDocument;

            if (active == null)
            {
                return;
            }

            ContextMenuService service = this.radDock1.GetService <ContextMenuService>();

            if (service == null)
            {
                return;
            }

            Rectangle bounds = this.contextRadDropDownButton.Bounds;

            bounds = this.contextRadDropDownButton.Parent.RectangleToScreen(bounds);
            Point location = new Point(bounds.X, bounds.Bottom + 1);

            service.DisplayContextMenu(active, location);
        }