コード例 #1
0
ファイル: MainWindow.cs プロジェクト: yunatoomi/DGLE
    protected void OnAColorCodeChanged(object sender, EventArgs e)
    {
        if (alphaColorCodeHandler.IsItEventOrigin)
        {
            alphaColorCodeHandler.ParseValue();

            if (alphaColorCodeHandler.ValueIsCorrect)
            {
                colorCodeHandler.SetupCode(alphaColorCodeHandler.Color);
                colorViewHandler.SetupColor(colorCode.Text);
                colorScalesHandler.SetupScales(colorViewHandler.Red,
                                               colorViewHandler.Green,
                                               colorViewHandler.Blue,
                                               alphaColorCodeHandler.Alpha);
                colorSpectrum.ClickProcessing(colorViewHandler.Red,
                                              colorViewHandler.Green,
                                              colorViewHandler.Blue);
                colorBrightness.ClickProcessing(colorSpectrum.ArcX,
                                                colorSpectrum.ArcY);
                colorSaturation.ClickProcessing(colorSpectrum.NativeRed,
                                                colorSpectrum.NativeGreen,
                                                colorSpectrum.NativeBlue);
                colorSquare.ClickProcessing(colorSaturation.X, colorBrightness.Y,
                                            colorBrightness.SpectrX);
                alphaView.ClickProcessing(colorViewHandler.Red,
                                          colorViewHandler.Green,
                                          colorViewHandler.Blue,
                                          alphaColorCodeHandler.Alpha);
            }
        }
        else
        {
            alphaColorCodeHandler.IsItEventOrigin = true;
        }
    }