예제 #1
0
        /// <summary>
        /// Raises the SplitClick event.
        /// </summary>
        /// <param name="e">The event arguments.</param>
        protected virtual void OnSplitClick(DropDownMenuEventArgs e)
        {
            DropDownClick?.Invoke(this, new EventArgs());

            if (SplitMenu == null)
            {
                return;
            }

            DropDownOpening?.Invoke(this, e);

            if (e.CancelDropdown)
            {
                return;
            }

            Point bottomLeft = new Point(e.DrawArea.Left, e.DrawArea.Bottom);

            SplitMenu.Width = e.DrawArea.Width;
            SplitMenu.Show(this, bottomLeft);
        }
예제 #2
0
 protected void OnDropClick()
 {
     DropDownClick?.Invoke(this, EventArgs.Empty);
     ShowDropDown(ToolShowMode.Default);
 }