aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.SharedUI/Converters
diff options
context:
space:
mode:
authorRoy Ben Shabat <Roy.mail.net@gmail.com>2020-03-15 01:55:42 +0200
committerRoy Ben Shabat <Roy.mail.net@gmail.com>2020-03-15 01:55:42 +0200
commit96fe20a20e7c107473cefeda3b06950955952bec (patch)
tree0c7efeb2a332eabdab4a551734eb94f4828aa381 /Software/Visual_Studio/Tango.SharedUI/Converters
parentbb82e09c0080cacec65512805ac88f6b3416c3f2 (diff)
downloadTango-96fe20a20e7c107473cefeda3b06950955952bec.tar.gz
Tango-96fe20a20e7c107473cefeda3b06950955952bec.zip
Improved Console.
Increased SignalR adapter connect timeout. Implemented Tango.FileSystem !!!
Diffstat (limited to 'Software/Visual_Studio/Tango.SharedUI/Converters')
-rw-r--r--Software/Visual_Studio/Tango.SharedUI/Converters/DateTimeUtcToLocalDateTime.cs30
1 files changed, 30 insertions, 0 deletions
diff --git a/Software/Visual_Studio/Tango.SharedUI/Converters/DateTimeUtcToLocalDateTime.cs b/Software/Visual_Studio/Tango.SharedUI/Converters/DateTimeUtcToLocalDateTime.cs
new file mode 100644
index 000000000..7ce4a6532
--- /dev/null
+++ b/Software/Visual_Studio/Tango.SharedUI/Converters/DateTimeUtcToLocalDateTime.cs
@@ -0,0 +1,30 @@
+using System;
+using System.Collections.Generic;
+using System.Globalization;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Data;
+
+namespace Tango.SharedUI.Converters
+{
+ public class DateTimeUtcToLocalDateTime : IValueConverter
+ {
+ public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
+ {
+ try
+ {
+ return ((DateTime)value).ToLocalTime();
+ }
+ catch
+ {
+ return value;
+ }
+ }
+
+ public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
+ {
+ throw new NotImplementedException();
+ }
+ }
+}