[chronojump/FS-TFT-Menu] Constants.ModeFolder () to return the folder of a mode



commit d58ae92b5f9f1062fa290a5dbd4acb16240c3d05
Author: Xavier de Blas <xaviblas gmail com>
Date:   Wed May 4 14:08:18 2022 +0200

    Constants.ModeFolder () to return the folder of a mode

 src/constants.cs | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
---
diff --git a/src/constants.cs b/src/constants.cs
index 97f1e21f0..c45d875e7 100644
--- a/src/constants.cs
+++ b/src/constants.cs
@@ -1049,6 +1049,20 @@ public class Constants
                POWERGRAVITATORY, POWERINERTIAL,
                FORCESENSOR, RT, OTHER } //OTHER can be: Multichronopic, Pulse
 
+       public static string ModeFolder (Constants.Modes mode)
+       {
+               if(mode == Constants.Modes.RUNSENCODER)
+                       return "raceAnalyzer";
+               else if(mode == Constants.Modes.POWERGRAVITATORY)
+                       return "encoder";
+               else if(mode == Constants.Modes.POWERINERTIAL)
+                       return "encoder";
+               else if(mode == Constants.Modes.FORCESENSOR)
+                       return "forceSensor";
+               else
+                       return ""; //should never happen
+       }
+
        public static string All = "All";
        public static string None = "None";
        public static string Invert = "Invert";


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