// MARK: Error Correction Interaction private void LeftHindChart_MouseRightButtonUp(object sender, System.Windows.Input.MouseButtonEventArgs e) { if (HindLeftInStance[GaitCurrentFrame] == 1) { HindLeftInStance[GaitCurrentFrame] = 0; //if the user right clicked the chart flipped the 0 (swing) to 1 (stance) or vice versa } else { HindLeftInStance[GaitCurrentFrame] = 1; } if (!GaitErrorFrames.Contains(GaitCurrentFrame)) { GaitErrorFrames.Add(GaitCurrentFrame); //add the corrected frame number to a list so we can keep track of all corrected frames } ((ObservablePoint)HindLeftObservables[GaitCurrentFrame]).Y = HindLeftInStance[GaitCurrentFrame]; //and update the actual 0 or 1 value in the corresponding chart values (ObservablePoint changes update the chart automatically) SetStaticData(); }
private void RightFrontChart_MouseRightButtonUp(object sender, System.Windows.Input.MouseButtonEventArgs e) { if (FrontRightInStance[GaitCurrentFrame] == 1) { FrontRightInStance[GaitCurrentFrame] = 0; } else { FrontRightInStance[GaitCurrentFrame] = 1; } if (!GaitErrorFrames.Contains(GaitCurrentFrame)) { GaitErrorFrames.Add(GaitCurrentFrame); } ((ObservablePoint)FrontRightObservables[GaitCurrentFrame]).Y = FrontRightInStance[GaitCurrentFrame]; SetStaticData(); }