Fix Page.DisplayAlert's message format converting
authorKangho Hur <kangho.hur@samsung.com>
Thu, 16 Mar 2017 00:26:10 +0000 (09:26 +0900)
committerKangho Hur <kangho.hur@samsung.com>
Mon, 10 Jul 2017 02:11:20 +0000 (11:11 +0900)
TASK=TCAPI-2218

- "\r\n" or Environment.NewLine is available.

Change-Id: I4550f63060cdb6e794762f66c3ec1c6e491bfb65

Xamarin.Forms.Platform.Tizen/FormsApplication.cs

index 57efa3f..66467b7 100644 (file)
@@ -166,11 +166,11 @@ namespace Xamarin.Forms.Platform.Tizen
                                {
                                        Native.Dialog alert = new Native.Dialog(Forms.Context.MainWindow);
                                        alert.Title = arguments.Title;
+                                       var message = arguments.Message.Replace("&", "&amp;").Replace("<", "&lt;").Replace(">", "&gt;").Replace(Environment.NewLine, "<br>");
                                        var label = new ELabel(alert)
                                        {
-                                               Text = "<span font_size=30 color=#000000>" + arguments.Message + "<\\span>",
+                                               Text = "<span font_size=30 color=#000000>" + message + "<\\span>",
                                        };
-
                                        label.Show();
 
                                        var box = new Box(alert);