Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 26 additions & 5 deletions SourceCode/AgLibrary/Settings/XmlSettingsHandler.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using AgLibrary.Logging;
using AgLibrary.Logging;
using System;
using System.Collections;
using System.Collections.Generic;
Expand Down Expand Up @@ -152,11 +152,32 @@
}
else if (fieldType.IsClass)
{
// Deserialize XML into the custom object
var serializer = new XmlSerializer(fieldType);
var nestedObj = serializer.Deserialize(reader);
pinfo.SetValue(obj, nestedObj);
try
{

if (reader.NodeType == XmlNodeType.Element && !reader.IsEmptyElement)
{
string innerXml = reader.ReadOuterXml().Trim();
innerXml = innerXml.Replace(">True<", ">true<").Replace(">False<", ">false<");

if (!string.IsNullOrEmpty(innerXml))
{
using (StringReader stringReader = new StringReader(innerXml))
{
var serializer = new XmlSerializer(fieldType);
object nestedObj = serializer.Deserialize(stringReader);
pinfo.SetValue(obj, nestedObj);

}
}
}
}
catch (Exception ex)

Check warning on line 175 in SourceCode/AgLibrary/Settings/XmlSettingsHandler.cs

View workflow job for this annotation

GitHub Actions / build-and-release

The variable 'ex' is declared but never used

Check warning on line 175 in SourceCode/AgLibrary/Settings/XmlSettingsHandler.cs

View workflow job for this annotation

GitHub Actions / build

The variable 'ex' is declared but never used

Check warning on line 175 in SourceCode/AgLibrary/Settings/XmlSettingsHandler.cs

View workflow job for this annotation

GitHub Actions / build

The variable 'ex' is declared but never used
{

}
}

else
{
if (Debugger.IsAttached)
Expand Down
47 changes: 21 additions & 26 deletions SourceCode/GPS/Classes/CFeatureSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,32 +6,27 @@ public CFeatureSettings()
{ }

//public bool ;
public bool isHeadlandOn = true;

public bool isTramOn = false;
public bool isBoundaryOn = true;
public bool isBndContourOn = false;
public bool isRecPathOn = false;
public bool isABSmoothOn = false;

public bool isHideContourOn = false;
public bool isWebCamOn = false;
public bool isOffsetFixOn = false;
public bool isAgIOOn = true;

public bool isContourOn = true;
public bool isYouTurnOn = true;
public bool isSteerModeOn = true;

public bool isManualSectionOn = true;
public bool isAutoSectionOn = true;
public bool isCycleLinesOn = true;
public bool isABLineOn = true;
public bool isCurveOn = true;
public bool isAutoSteerOn = true;

public bool isUTurnOn = true;
public bool isLateralOn = true;
public bool isHeadlandOn { get; set; } = true;
public bool isTramOn { get; set; } = false;
public bool isBoundaryOn { get; set; } = true;
public bool isBndContourOn { get; set; } = false;
public bool isRecPathOn { get; set; } = false;
public bool isABSmoothOn { get; set; } = false;
public bool isHideContourOn { get; set; } = false;
public bool isWebCamOn { get; set; } = false;
public bool isOffsetFixOn { get; set; } = false;
public bool isAgIOOn { get; set; } = true;
public bool isContourOn { get; set; } = true;
public bool isYouTurnOn { get; set; } = true;
public bool isSteerModeOn { get; set; } = true;
public bool isManualSectionOn { get; set; } = true;
public bool isAutoSectionOn { get; set; } = true;
public bool isCycleLinesOn { get; set; } = true;
public bool isABLineOn { get; set; } = true;
public bool isCurveOn { get; set; } = true;
public bool isAutoSteerOn { get; set; } = true;
public bool isUTurnOn { get; set; } = true;
public bool isLateralOn { get; set; } = true;

public CFeatureSettings(CFeatureSettings _feature)
{
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.da.resx
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,7 @@ Rækkefølgen du klikker på dem, angiver placeringen nedefra og op</value>
<value>Nord Vest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Ny</value>
<value>Ny fra standard</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Næste styrelinje</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.de.resx
Original file line number Diff line number Diff line change
Expand Up @@ -646,7 +646,7 @@
<value>Nordwest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Neu</value>
<value>Neu aus Standard</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Nächste Linie</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.es.resx
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ El orden en que los presiones será el orden en que aparecerán en el menú de a
<value>Noroeste</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nuevo</value>
<value>Nuevo desde estándar</value>
</data>
<data name="gsNoABLineActive" xml:space="preserve">
<value>Ninguna Línea AB activa</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.fi.resx
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@ Haluatko jatkaa?</value>
<value>Luode</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Uusi</value>
<value>Uusi oletusarvosta</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Seuraava Linja</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.fr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -726,7 +726,7 @@ L'ordre dans lequel vous cliquez, sera l'ordre dans lequel ils apparaîtrons dan
<value>NOuest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nouveau</value>
<value>Nouveau De la norme</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Ligne de guidage suivante</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.hu.resx
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@ A választott sorrend alapján fognak megjelenni alulról felfelé.</value>
<value>Északnyugat</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Új</value>
<value>Új alapértelmezésből</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Következő nyomvonal</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.it.resx
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@
<value>Nord Ovest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nuovo</value>
<value>Nuovo da predefinito</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Prossima Linea AB</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.lt.resx
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@
<value>Šiaurės vakarai</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Naujas</value>
<value>Nauja iš numatytojo</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Sekanti navigavimo linija</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.lv.resx
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@
<value>Z Rietumi</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Jauns</value>
<value>Jauns Nu nūklusājuma .</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Nākamā navigācijas līnija</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.nl.resx
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ De volgorde waarin u ze indrukt, is de volgorde waarin ze van onder naar boven i
<value>NoordWest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nieuw</value>
<value>Nieuw vanaf Standaard</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Volgende lijn</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.no.resx
Original file line number Diff line number Diff line change
Expand Up @@ -730,7 +730,7 @@
<value>NVest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Ny</value>
<value>Ny fra standard</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Neste veiledningslinje</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.pl.resx
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,7 @@ Kolejność, w jakiej je naciśniesz, będzie kolejnością, w jakiej pojawią s
<value>Pn-Zach</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nowy</value>
<value>Nowy z domyślnego</value>
</data>
<data name="gsNight" xml:space="preserve">
<value>Noc</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.pt.resx
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@
<value>Noroeste</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Novo</value>
<value>Novo a partir do padrão</value>
</data>
<data name="gsNoABLineActive" xml:space="preserve">
<value>Sem ABLine ativo</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -747,7 +747,7 @@ The order you push them will be the order they appear on the menu from bottom up
<value>NWest</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>New</value>
<value>New From Default</value>
</data>
<data name="gsNextGuidanceLine" xml:space="preserve">
<value>Next Guidance Line</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.ru.resx
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@
<value>Северо-Запад</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Новый</value>
<value>Новый по умолчанию</value>
</data>
<data name="gsNight" xml:space="preserve">
<value>Ночь</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.sk.resx
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@
<value>Severo-Západ</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nový</value>
<value>Novinka od štandardu</value>
</data>
<data name="gsNoABLineActive" xml:space="preserve">
<value>Žiadna AB línia aktívna</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.sr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@
<value>Severozapad</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Nova</value>
<value>Novo Od podrazumevanog</value>
</data>
<data name="gsNight" xml:space="preserve">
<value>Noć</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.tr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@
<value>K Batı</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Yeni</value>
<value>Standarttan Yeni</value>
</data>
<data name="gsNoABLineActive" xml:space="preserve">
<value>ABLine Etkin Değil</value>
Expand Down
2 changes: 1 addition & 1 deletion SourceCode/GPS/Culture/gStr.uk.resx
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@
<value>Північний Захід</value>
</data>
<data name="gsNew" xml:space="preserve">
<value>Новий</value>
<value>Nove zi standartu</value>
</data>
<data name="gsNoABLineActive" xml:space="preserve">
<value>Немає активних (AB) ліній</value>
Expand Down
5 changes: 3 additions & 2 deletions SourceCode/GPS/Forms/Position.designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

69 changes: 68 additions & 1 deletion SourceCode/GPS/Forms/Settings/ConfigVehicle.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading