[chronojump] Treeview jumps with RSI



commit f7a97f1e2f5ce0b87a3eaea9b00fcba0a4e741d6
Author: Xavier de Blas <xaviblas gmail com>
Date:   Fri Oct 15 13:45:45 2021 +0200

    Treeview jumps with RSI

 src/jump.cs          | 4 ++++
 src/treeview/jump.cs | 9 +++++++++
 2 files changed, 13 insertions(+)
---
diff --git a/src/jump.cs b/src/jump.cs
index 1dfbbaa6d..312dabd6b 100644
--- a/src/jump.cs
+++ b/src/jump.cs
@@ -130,6 +130,10 @@ public class Jump : Event
                set { weight = value; }
        }
 
+       public double RSI {
+               get { return UtilAll.DivideSafe(Util.GetHeightInMeters(tv), tc); }
+       }
+
        public double Angle {
                get { return angle; }
                set { angle = value; }
diff --git a/src/treeview/jump.cs b/src/treeview/jump.cs
index 55d47061b..10c9697ce 100644
--- a/src/treeview/jump.cs
+++ b/src/treeview/jump.cs
@@ -34,6 +34,7 @@ public class TreeViewJumps : TreeViewEvent
        protected string powerName = Catalog.GetString("Power") + "\n(W)";
        protected string stiffnessName = Catalog.GetString("Stiffness") + "\n(N/m)";
        protected string initialSpeedName = Catalog.GetString("Initial Speed");
+       protected string rsiName = "RSI" + "\n(m/s)";
        protected string angleName = Catalog.GetString("Angle");
        protected string datetimeName = Catalog.GetString("Date");
 
@@ -95,6 +96,8 @@ public class TreeViewJumps : TreeViewEvent
                        i ++;
                if (preferences.showInitialSpeed) 
                        i ++;
+               if (preferences.showJumpRSI)
+                       i ++;
                if (preferences.showAngle) 
                        i ++;
                if (preferences.showQIndex || preferences.showDjIndex) 
@@ -113,6 +116,8 @@ public class TreeViewJumps : TreeViewEvent
                        i ++;
                if (preferences.showInitialSpeed) 
                        i ++;
+               if (preferences.showJumpRSI)
+                       i ++;
                if (preferences.showAngle) 
                        i ++;
                if (preferences.showQIndex || preferences.showDjIndex) 
@@ -138,6 +143,8 @@ public class TreeViewJumps : TreeViewEvent
                        columnsString[i++] = stiffnessName;
                if (preferences.showInitialSpeed) 
                        columnsString[i++] = initialSpeedName;
+               if (preferences.showJumpRSI)
+                       columnsString[i++] = rsiName;
                if (preferences.showAngle) 
                        columnsString[i++] = angleName;
                if (preferences.showQIndex) 
@@ -223,6 +230,8 @@ public class TreeViewJumps : TreeViewEvent
                        myData[count++] = Convert.ToInt32(newJump.Stiffness(personWeight, 
weightInKg)).ToString();
                if (preferences.showInitialSpeed) 
                        myData[count++] = Util.TrimDecimals(Util.GetInitialSpeed(newJump.Tv.ToString(), 
preferences.metersSecondsPreferred), pDN);
+               if (preferences.showJumpRSI)
+                       myData[count++] = Util.TrimDecimals(newJump.RSI, pDN);
                if (preferences.showAngle) 
                        myData[count++] = Util.TrimDecimals(newJump.Angle.ToString(), pDN);
                if (preferences.showQIndex)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]