protected virtual void OnButtonClicked(object sender, System.EventArgs e) { ColorSelectDialog colorDialog = new ColorSelectDialog(); colorDialog.ColorSelection.CurrentColor = this.color; if(colorDialog.Run() == (int)ResponseType.Ok) this.Color = colorDialog.ColorSelection.CurrentColor; colorDialog.Destroy(); }
protected virtual void ColorSelectionButtonClicked(object sender, System.EventArgs e) { ColorSelectDialog colorDialog = new ColorSelectDialog(); int res = colorDialog.Run(); if(res == (int)ResponseType.Ok) this.shapeManager.Selected.Colorize(colorDialog.ColorSelection.CurrentColor, ((double)colorDialog.ColorSelection.CurrentAlpha)/65025); colorDialog.Destroy(); this.drawingarea.QueueDraw(); }