Fixed Naviitem.TitleBarBackgroundColor is Color.Default 33/109333/1
authorchungryeol lim <cdark.lim@samsung.com>
Tue, 10 Jan 2017 04:47:38 +0000 (13:47 +0900)
committerchungryeol lim <cdark.lim@samsung.com>
Tue, 10 Jan 2017 04:47:38 +0000 (13:47 +0900)
Change-Id: I85ead73f548fda20126403a1dc3b695b50472b05
Signed-off-by: chungryeol lim <cdark.lim@samsung.com>
ElmSharp.Test/TC/NaviframeTest2.cs
ElmSharp/ElmSharp/NaviItem.cs

index 3de3e41..064640b 100644 (file)
@@ -89,7 +89,14 @@ namespace ElmSharp.Test
 
             Button barChange = new Button(parent)
             {
-                Text = "TitleTextColor & BarColor",
+                Text = "TitleBarColor Change",
+                WeightX = 1,
+                AlignmentX = -1,
+            };
+
+            Button barColorDefault = new Button(parent)
+            {
+                Text = "TitleBarColor - Default",
                 WeightX = 1,
                 AlignmentX = -1,
             };
@@ -101,6 +108,7 @@ namespace ElmSharp.Test
             insertAfterTop.Show();
             removeTop.Show();
             barChange.Show();
+            barColorDefault.Show();
 
             push.Clicked += (s, e) =>
             {
@@ -144,6 +152,15 @@ namespace ElmSharp.Test
                 }
             };
 
+            barColorDefault.Clicked += (s, e) =>
+            {
+                int currentIndex = _navi.NavigationStack.Count - 1;
+                if (currentIndex >= 0)
+                {
+                    _navi.NavigationStack[currentIndex].TitleBarBackgroundColor = Color.Default;
+                }
+            };
+
             box.PackEnd(label);
             box.PackEnd(push);
             box.PackEnd(pop);
@@ -151,6 +168,7 @@ namespace ElmSharp.Test
             box.PackEnd(insertAfterTop);
             box.PackEnd(removeTop);
             box.PackEnd(barChange);
+            box.PackEnd(barColorDefault);
 
             return box;
         }
index 3e92445..d3f3bde 100644 (file)
@@ -67,8 +67,7 @@ namespace ElmSharp
             {
                 if (value.IsDefault)
                 {
-                    Console.WriteLine("ItemObject instance doesn't support to set TitleBarBackgroundColor to Color.Default.");
-                    //TODO. Soon we will support the "elm_object_item_color_class_del" function in EFL.
+                    Interop.Elementary.elm_object_item_color_class_del(Handle, "bg_title");
                 }
                 else
                 {