Example #1
0
        // hepler function
        protected virtual void OnWindowButtonStateChange(WindowButtonState state, WindowButton button)
        {
            switch (state)
            {
            case WindowButtonState.Normal:
                button.Visibility = Visibility.Visible;
                button.IsEnabled  = true;
                break;

            case WindowButtonState.Disabled:
                button.Visibility = Visibility.Visible;
                button.IsEnabled  = false;
                break;

            case WindowButtonState.None:
                button.Visibility = Visibility.Collapsed;
                break;
            }
        }
Example #2
0
        // hepler function
        protected virtual void OnWindowButtonStateChange(WindowButtonState state, WindowButton button)
        {
            switch (state)
            {
                case WindowButtonState.Normal:
                    button.Visibility = Visibility.Visible;
                    button.IsEnabled = true;
                    break;

                case WindowButtonState.Disabled:
                    button.Visibility = Visibility.Visible;
                    button.IsEnabled = false;
                    break;

                case WindowButtonState.None:
                    button.Visibility = Visibility.Collapsed;
                    break;
            }
        }