예제 #1
0
 void OnExpansionWindowVisibilityChanged(ExpansionWindow e)
 {
     if (Expanded && e.Visible)
     {
         HideExpansionWindow();
         e.Show();
     }
 }
예제 #2
0
        public ExpandingSelector(CheckBox checkBox, ExpansionWindow expansionWindow)
        {
            this.checkBox         = checkBox;
            this.defaultTexture   = checkBox.Texture;
            this.defaultImageRect = checkBox.ImageRect;

            checkBox.Toggled    += MainBoxToggled;
            checkBox.HoverBegin += OnHoverBegin;
            checkBox.HoverEnd   += OnHoverEnd;

            this.expansionWindow = expansionWindow;
            expansionWindow.VisibilityChanged += OnExpansionWindowVisibilityChanged;

            this.checkBoxes = new List <CheckBox>();
        }