diff --git a/ReactionRecorder.cs b/ReactionRecorder.cs --- a/ReactionRecorder.cs +++ b/ReactionRecorder.cs @@ -114,7 +114,8 @@ namespace DesertPaintLab public int Y { get; private set; } public int ScreenWidth { get; private set; } public int ScreenHeight { get; private set; } - public PaintColor RecordedColor { get; private set; } + private PaintColor _recordedColor = new PaintColor(); + public PaintColor RecordedColor { get { return _recordedColor; } private set { _recordedColor.Set(value); } } public int RedBarX { get; private set; } public int RedBarY { get; private set; } @@ -459,6 +460,8 @@ namespace DesertPaintLab int redPixelStart = 0; ScreenWidth = screenshotWidth; ScreenHeight = screenshotHeight; + IsCaptured = false; + _recordedColor.Clear(); IsCaptured = false; if (!firstRun) diff --git a/UI/CaptureView.cs b/UI/CaptureView.cs --- a/UI/CaptureView.cs +++ b/UI/CaptureView.cs @@ -288,7 +288,7 @@ namespace DesertPaintLab notifyCaptureComplete = new Gtk.ThreadNotify(new Gtk.ReadyEvent(NotifyCaptureComplete)); } - this.reactionSwatch.Color = new PaintColor("Searching", "00", "00", "00"); + this.reactionSwatch.Clear(); Thread thr = new Thread(new ThreadStart(this.CaptureReactionThread)); thr.Priority = ThreadPriority.AboveNormal; @@ -420,8 +420,6 @@ namespace DesertPaintLab { recordButton.Sensitive = recordEnabled; } - - captureButton.Sensitive = false; } else { @@ -442,8 +440,7 @@ namespace DesertPaintLab ingredient1ComboBox.Sensitive = true; ingredient2ComboBox.Sensitive = true; - ingredient3ComboBox.Sensitive = false; - UpdateIngredients(); + ingredient3ComboBox.Sensitive = (GetSelectedReagentName(1) != null) && (GetSelectedReagentName(2) != null); } private void NotifyCaptureComplete()