[chronojump] Fix on list_d store: '=' to '_'
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] Fix on list_d store: '=' to '_'
- Date: Sun, 2 Aug 2015 16:00:18 +0000 (UTC)
commit e4c5091362044dda3b83aa7a74da4a2d97253704
Author: Xavier de Blas <xaviblas gmail com>
Date: Sun Aug 2 13:45:51 2015 +0200
Fix on list_d store: '=' to '_'
chronojump_config.txt | 5 +++--
src/config.cs | 2 +-
src/encoder.cs | 6 +++---
3 files changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/chronojump_config.txt b/chronojump_config.txt
index 24bbee6..0d81e7f 100644
--- a/chronojump_config.txt
+++ b/chronojump_config.txt
@@ -57,9 +57,10 @@ PersonWinHide=TRUE
EncoderAnalyzeHide=FALSE
#EncoderConfiguration if exists, this will be used and cannot be changed
-#name:d:D:anglePush:angleWeight:inertiaMachine:gearedDown:inertiaTotal:extraWeightN:extraWeightGrams:extraWeightLenght
+#name:d:D:anglePush:angleWeight:inertiaMachine:gearedDown:inertiaTotal:extraWeightN:extraWeightGrams:extraWeightLenght:list_d
+#list_d is list of anchorages in centimeters. each value separated by '_'
#default: EncoderConfiguration=
-EncoderConfiguration=ROTARYAXISINERTIAL:4:-1:-1:-1:42:1:71:2:300:7
+EncoderConfiguration=ROTARYAXISINERTIAL:4:-1:-1:-1:42:1:71:2:300:7:4_8_12
#Session modes:
#STANDARD: default mode where sessions are created by user
diff --git a/src/config.cs b/src/config.cs
index 7a88451..bc990a7 100644
--- a/src/config.cs
+++ b/src/config.cs
@@ -127,7 +127,7 @@ public class Config
string line = reader.ReadLine();
if (line != "" && line[0] != '#')
{
- string [] parts = line.Split(new char[] {'='});
+ string [] parts = line.Split(new char[] {'_'});
if(parts.Length == 2 && parts[0] ==
"EncoderConfiguration")
line = "EncoderConfiguration=" +
EconfNew.ToStringOutput(EncoderConfiguration.Outputs.SQL);
}
diff --git a/src/encoder.cs b/src/encoder.cs
index 06f0b51..9b1caf5 100644
--- a/src/encoder.cs
+++ b/src/encoder.cs
@@ -1288,11 +1288,11 @@ public class EncoderConfiguration {
this.list_d[0] = this.d;
}
}
- //list_d contains the different diameters (byt eh anchorages). They are stored as '='
+ //list_d contains the different diameters (byt eh anchorages). They are stored as '_'
private List<double> readList_d(string listFromSQL)
{
List<double> l = new List<double>();
- string [] strFull = listFromSQL.Split(new char[] {'='});
+ string [] strFull = listFromSQL.Split(new char[] {'_'});
foreach (string s in strFull) {
double d = Convert.ToDouble(Util.ChangeDecimalSeparator(s));
l.Add(d);
@@ -1364,7 +1364,7 @@ public class EncoderConfiguration {
string sep = "";
foreach(double d in l) {
str += sep + Util.ConvertToPoint(d);
- sep = "=";
+ sep = "_";
}
return str;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]