Interaction logic for ColorSelector.xaml
Inheritance: System.Windows.Window
Ejemplo n.º 1
0
        private void FillColorButton_Click(object sender, RoutedEventArgs e)
        {
            var colorDialog = new ColorSelector(UserSettings.All.InsertFillColor, false) { Owner = this };
            var result = colorDialog.ShowDialog();

            if (result.HasValue && result.Value)
                UserSettings.All.InsertFillColor = colorDialog.SelectedColor;
        }
Ejemplo n.º 2
0
        private void CustomColorStackPanel_MouseDown(object sender, MouseButtonEventArgs e)
        {
            var colorPicker = new ColorSelector(Properties.Settings.Default.CreateLastSelectedColor, false);
            colorPicker.Owner = this;
            var result = colorPicker.ShowDialog();

            if (result.HasValue && result.Value)
            {
                Properties.Settings.Default.CreateLastSelectedColor = colorPicker.SelectedColor;

                BackCombo.SelectedIndex = 4;
            }
        }
Ejemplo n.º 3
0
        private void CustomColorStackPanel_MouseDown(object sender, MouseButtonEventArgs e)
        {
            var colorPicker = new ColorSelector(Properties.Settings.Default.CreateLastSelectedColor, false);

            colorPicker.Owner = this;
            var result = colorPicker.ShowDialog();

            if (result.HasValue && result.Value)
            {
                Properties.Settings.Default.CreateLastSelectedColor = colorPicker.SelectedColor;

                BackCombo.SelectedIndex = 4;
            }
        }
Ejemplo n.º 4
0
        private void FillColorButton_Click(object sender, RoutedEventArgs e)
        {
            var colorDialog = new ColorSelector(Settings.Default.InsertFillColor, false);
            colorDialog.Owner = this;
            var result = colorDialog.ShowDialog();

            if (result.HasValue && result.Value)
            {
                Settings.Default.InsertFillColor = colorDialog.SelectedColor;
            }
        }
Ejemplo n.º 5
0
        private void NewAnimationBackgroundColor_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            var colorPicker = new ColorSelector(Settings.Default.NewImageColor);
            colorPicker.Owner = this;
            var result = colorPicker.ShowDialog();

            if (result.HasValue && result.Value)
            {
                Settings.Default.NewImageColor = colorPicker.SelectedColor;
            }
        }
Ejemplo n.º 6
0
        private void FreeDrawingColorBorder_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            var colorPicker = new ColorSelector(Settings.Default.FreeDrawingColor);
            colorPicker.Owner = this;
            var result = colorPicker.ShowDialog();

            if (result.HasValue && result.Value)
            {
                Settings.Default.FreeDrawingColor = colorPicker.SelectedColor;
            }
        }
Ejemplo n.º 7
0
        private void ColorBorder_OnMouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            var border = sender as Border;
            if (border == null) return;

            var color = ((SolidColorBrush)border.Background).Color;

            var colorPicker = new ColorSelector(color);
            colorPicker.Owner = this;
            var result = colorPicker.ShowDialog();

            if (result.HasValue && result.Value)
            {
                border.Background = new SolidColorBrush(colorPicker.SelectedColor);

                CheckScheme(false);
            }
        }