コード例 #1
0
        public void ShowColorPickerEditor()
        {
            if (_colorEditorWindow == null)
            {
                _colorEditorWindow         = new ColorEditorWindow();
                _colorEditorWindow.Content = _colorEditorViewModel;
                _colorEditorViewModel.OpenColorPickerRequested += ColorEditorViewModel_OpenColorPickerRequested;
            }

            _colorEditorViewModel.Initialize();
            _colorEditorWindow.Show();
        }
コード例 #2
0
ファイル: AppStateHandler.cs プロジェクト: rhorber/PowerToys
        private void ShowColorPickerEditor()
        {
            if (_colorEditorWindow == null)
            {
                _colorEditorWindow         = new ColorEditorWindow(this);
                _colorEditorWindow.Content = _colorEditorViewModel;
                _colorEditorViewModel.OpenColorPickerRequested += ColorEditorViewModel_OpenColorPickerRequested;
                _colorEditorViewModel.OpenColorPickerRequested += (object sender, EventArgs e) =>
                {
                    SessionEventHelper.Event.EditorColorPickerOpened = true;
                };
            }

            _colorEditorViewModel.Initialize();
            _colorEditorWindow.Show();
            SessionEventHelper.Event.EditorOpened = true;
        }
コード例 #3
0
    public static void Create()
    {
        ColorEditorWindow window = GetWindow <ColorEditorWindow>();

        window.minSize = new Vector2(320, 320);
    }