From cddc77a6a645bb951b4849729e8f6e53cd8e48e8 Mon Sep 17 00:00:00 2001 From: "Moonhee, Choi" Date: Tue, 8 Dec 2020 19:24:05 +0900 Subject: [PATCH] [NUI] Remove build warning - CA2241 --- src/Tizen.NUI/src/internal/XamlBinding/BindingExpression.cs | 8 ++++---- src/Tizen.NUI/src/public/XamlBinding/BindableObject.cs | 2 +- .../src/public/XamlBinding/Interactivity/EventTrigger.cs | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Tizen.NUI/src/internal/XamlBinding/BindingExpression.cs b/src/Tizen.NUI/src/internal/XamlBinding/BindingExpression.cs index e6df866..e754104 100755 --- a/src/Tizen.NUI/src/internal/XamlBinding/BindingExpression.cs +++ b/src/Tizen.NUI/src/internal/XamlBinding/BindingExpression.cs @@ -137,7 +137,7 @@ namespace Tizen.NUI.Binding { if ((needsGetter && part.LastGetter == null) || (needsSetter && part.NextPart == null && part.LastSetter == null)) { - Console.WriteLine("Binding", PropertyNotFoundErrorMessage, part.Content, current, target.GetType(), property.PropertyName); + Console.WriteLine($"Binding, {PropertyNotFoundErrorMessage}, {part.Content}, {current}, {target.GetType()}, {property.PropertyName}"); break; } } @@ -166,7 +166,7 @@ namespace Tizen.NUI.Binding if (!TryConvert(ref value, property.ReturnType, true)) { - Console.WriteLine("Binding", "{0} can not be converted to type '{1}'", value, property.ReturnType); + Console.WriteLine($"Binding : {value} can not be converted to type {property.ReturnType}"); return; } @@ -178,7 +178,7 @@ namespace Tizen.NUI.Binding if (!TryConvert(ref value, part.SetterType, false)) { - Console.WriteLine("Binding", "{0} can not be converted to type '{1}'", value, part.SetterType); + Console.WriteLine($"Binding : {value} can not be converted to type {part.SetterType}"); return; } @@ -274,7 +274,7 @@ namespace Tizen.NUI.Binding { int index; if (!int.TryParse(part.Content, out index)) - Console.WriteLine("Binding", "{0} could not be parsed as an index for a {1}", part.Content, sourceType); + Console.WriteLine($"Binding : {part.Content} could not be parsed as an index for a {sourceType}"); else part.Arguments = new object[] { index }; diff --git a/src/Tizen.NUI/src/public/XamlBinding/BindableObject.cs b/src/Tizen.NUI/src/public/XamlBinding/BindableObject.cs index 4e33927..74e1368 100755 --- a/src/Tizen.NUI/src/public/XamlBinding/BindableObject.cs +++ b/src/Tizen.NUI/src/public/XamlBinding/BindableObject.cs @@ -599,7 +599,7 @@ namespace Tizen.NUI.Binding if (!converted && !property.TryConvert(ref value)) { - Console.WriteLine("SetValue", "Can not convert {0} to type '{1}'", value, property.ReturnType); + Console.WriteLine($"SetValue : Can not convert {value} to type {property.ReturnType}"); return; } diff --git a/src/Tizen.NUI/src/public/XamlBinding/Interactivity/EventTrigger.cs b/src/Tizen.NUI/src/public/XamlBinding/Interactivity/EventTrigger.cs index e163c5d..7066b70 100755 --- a/src/Tizen.NUI/src/public/XamlBinding/Interactivity/EventTrigger.cs +++ b/src/Tizen.NUI/src/public/XamlBinding/Interactivity/EventTrigger.cs @@ -78,7 +78,7 @@ namespace Tizen.NUI.Binding } catch (Exception) { - Console.WriteLine("EventTrigger", "Can not attach EventTrigger to {0}.{1}. Check if the handler exists and if the signature is right.", bindable.GetType(), Event); + Console.WriteLine($"EventTrigger", "Can not attach EventTrigger to {binding.GetType()}.{Evnet}. Check if the handler exists and if the signature is right."); } if (_eventinfo != null && _handlerdelegate != null) _eventinfo.AddEventHandler(bindable, _handlerdelegate); -- 2.7.4