Exemplo n.º 1
0
 private void OnCloseClicked()
 {
     if (_ignoreEvents)
     {
         return;
     }
     _visible = false;
     if (_colorPicker != null)
     {
         _colorPicker.component.isVisible = _visible;
     }
     _rgbPanel.isVisible           = _visible;
     _buttonsPanel.isVisible       = _visible;
     _savedSwatchesPanel.isVisible = _visible;
     EventVisibilityChanged?.Invoke(this, new ColorPanelVisibilityChangedEventArgs(this, _visible));
 }
Exemplo n.º 2
0
 private void OnColorButtonClicked(UIComponent component, UIMouseEventParameter eventParam)
 {
     if (_ignoreEvents)
     {
         return;
     }
     component.isInteractive = false;
     _ignoreEvents           = true;
     _visible = !_visible;
     if (_colorPicker != null)
     {
         _colorPicker.component.isVisible = _visible;
     }
     _rgbPanel.isVisible           = _visible;
     _buttonsPanel.isVisible       = _visible;
     _savedSwatchesPanel.isVisible = _visible;
     EventVisibilityChanged?.Invoke(this, new ColorPanelVisibilityChangedEventArgs(this, _visible));
     _ignoreEvents           = false;
     component.isInteractive = true;
 }