private void currentSplitButton_MouseEnter(object sender, EventArgs e) { if (this.dropDownOpened) { RadSplitButtonElement splitButton = sender as RadSplitButtonElement; if (splitButton != null) { // if the current split button is the sender doesn't do anything // else if another split button is the sender then hides // the current drop down and openes the sender's one if (splitButton == this.currentExpandedSplitButton) { return; } if (this.currentExpandedSplitButton != null) { this.currentExpandedSplitButton.HideDropDown(); } this.currentExpandedSplitButton = splitButton; if (!splitButton.IsDropDownShown) { splitButton.ShowDropDown(); } } } }
private void currentSplitButton_MouseEnter(object sender, EventArgs e) { if (!this.dropDownOpened) { return; } RadSplitButtonElement splitButtonElement = sender as RadSplitButtonElement; if (splitButtonElement == null || splitButtonElement == this.currentExpandedSplitButton) { return; } if (this.currentExpandedSplitButton != null) { this.currentExpandedSplitButton.HideDropDown(); } this.currentExpandedSplitButton = splitButtonElement; if (splitButtonElement.IsDropDownShown) { return; } splitButtonElement.ShowDropDown(); }