[chronojump] Encoder capture, curves, load do not check combo_encoder_exercise_capture by non-gtk thread. Now id an
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] Encoder capture, curves, load do not check combo_encoder_exercise_capture by non-gtk thread. Now id an
- Date: Tue, 8 Mar 2022 15:36:33 +0000 (UTC)
commit 26495a6d327bf81b1c16ea5fc5b805740f905c88
Author: Xavier de Blas <xaviblas gmail com>
Date: Tue Mar 8 16:35:04 2022 +0100
Encoder capture,curves,load do not check combo_encoder_exercise_capture by non-gtk thread. Now id and
english name is stored previously
src/gui/app1/encoder.cs | 25 +++++++++++++++++++------
1 file changed, 19 insertions(+), 6 deletions(-)
---
diff --git a/src/gui/app1/encoder.cs b/src/gui/app1/encoder.cs
index b8b8f3903..72050758d 100644
--- a/src/gui/app1/encoder.cs
+++ b/src/gui/app1/encoder.cs
@@ -418,6 +418,10 @@ public partial class ChronoJumpWindow
*/
EncoderSQL lastEncoderSQLSignal;
+ //combo_encoder_exercise_capture
+ private static int encoderComboExerciseCaptureStoredID;
+ private static string encoderComboExerciseCaptureStoredEnglishName;
+
/*
* CAPTURE is the capture from csharp (not from external python)
*
@@ -1479,7 +1483,7 @@ public partial class ChronoJumpWindow
"-1",
currentPerson.UniqueID,
currentSession.UniqueID,
- getExerciseIDFromEncoderCombo(exerciseCombos.CAPTURE),
+ encoderComboExerciseCaptureStoredID,
findEccon(true), //force ecS (ecc-conc separated)
laterality,
Util.ConvertToPoint(findMass(Constants.MassType.EXTRA)), //when save on sql,
do not include person weight
@@ -1492,8 +1496,7 @@ public partial class ChronoJumpWindow
"", videoURL, //status, videoURL
encoderConfigurationCurrent,
"","","", //future1, 2, 3
- Util.FindOnArray(':', 2, 1,
UtilGtk.ComboGetActive(combo_encoder_exercise_capture),
- encoderExercisesTranslationAndBodyPWeight) //exerciseName
(english)
+ encoderComboExerciseCaptureStoredEnglishName
);
}
@@ -6178,7 +6181,18 @@ public partial class ChronoJumpWindow
private void encoderThreadStart(encoderActions action)
{
encoderProcessCancel = false;
-
+
+ /*
+ stored here in order to not read the combo on non-gtk thread
+ used on CAPTURE -> encoderDoCaptureCsharp () -> setLastEncoderSQLSignal()
+ used on CURVES, LOAD - encoderDoCurvesGraphR_curves () -> setLastEncoderSQLSignal()
+ */
+ encoderComboExerciseCaptureStoredID = getExerciseIDFromEncoderCombo(exerciseCombos.CAPTURE);
+ encoderComboExerciseCaptureStoredEnglishName =
+ Util.FindOnArray(':', 2, 1, UtilGtk.ComboGetActive(combo_encoder_exercise_capture),
+ encoderExercisesTranslationAndBodyPWeight); //exerciseName
(english)
+
+
if(action == encoderActions.CAPTURE_BG)
{
shownWaitAtInertialCapture = false;
@@ -6427,8 +6441,7 @@ public partial class ChronoJumpWindow
LogB.Information("at load");
prepareEncoderGraphs(true, true);
-
-
+
//_______ 2) run stuff
//don't need because ItemToggled is deactivated during capture
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]