Remove windows style line ending
authorcskim <charles0.kim@samsung.com>
Wed, 15 Mar 2017 10:59:40 +0000 (19:59 +0900)
committerChulSeung Kim <charles0.kim@samsung.com>
Thu, 8 Jun 2017 09:34:47 +0000 (18:34 +0900)
Change-Id: Ia5d188313594896af5fa6d65c9e5494f83ea7c63

73 files changed:
LibTVRefCommonPortable/DataModels/AppControlAction.cs
LibTVRefCommonPortable/DataModels/AppShortcutInfo.cs
LibTVRefCommonPortable/DataModels/BTLaunchAction.cs
LibTVRefCommonPortable/DataModels/BTOffAction.cs
LibTVRefCommonPortable/DataModels/BTOnAction.cs
LibTVRefCommonPortable/DataModels/BTSettingShortcutInfo.cs
LibTVRefCommonPortable/DataModels/CommandAction.cs
LibTVRefCommonPortable/DataModels/DBItem.cs
LibTVRefCommonPortable/DataModels/FileSystemEventCustomArgs.cs
LibTVRefCommonPortable/DataModels/HomeMenuAppShortcutInfo.cs
LibTVRefCommonPortable/DataModels/IAction.cs
LibTVRefCommonPortable/DataModels/IDBItem.cs
LibTVRefCommonPortable/DataModels/IEnumerableItem.cs
LibTVRefCommonPortable/DataModels/MediaControlAction.cs
LibTVRefCommonPortable/DataModels/RecentShortcutInfo.cs
LibTVRefCommonPortable/DataModels/ShortcutInfo.cs
LibTVRefCommonPortable/DataModels/StateDescription.cs
LibTVRefCommonPortable/DataModels/WatcherType.cs
LibTVRefCommonPortable/DataModels/WiFiLaunchAction.cs
LibTVRefCommonPortable/DataModels/WiFiOffAction.cs
LibTVRefCommonPortable/DataModels/WiFiOnAction.cs
LibTVRefCommonPortable/DataModels/WiFiSettingShortcutInfo.cs
LibTVRefCommonPortable/LibTVRefCommonPortable.cs
LibTVRefCommonPortable/Models/AppShortcutController.cs
LibTVRefCommonPortable/Models/RecentShortcutController.cs
LibTVRefCommonPortable/Models/SettingShortcutController.cs
LibTVRefCommonPortable/Models/SettingShortcutFactory.cs
LibTVRefCommonPortable/Utils/AppControlUtils.cs
LibTVRefCommonPortable/Utils/AppShortcutStorage.cs
LibTVRefCommonPortable/Utils/DBUtil.cs
LibTVRefCommonPortable/Utils/DateUtils.cs
LibTVRefCommonPortable/Utils/DebuggingUtils.cs
LibTVRefCommonPortable/Utils/IAppControl.cs
LibTVRefCommonPortable/Utils/IApplicationManagerAPIs.cs
LibTVRefCommonPortable/Utils/IBTAPIs.cs
LibTVRefCommonPortable/Utils/IDBAPIs.cs
LibTVRefCommonPortable/Utils/IDebuggingAPIs.cs
LibTVRefCommonPortable/Utils/IFileSystemAPIs.cs
LibTVRefCommonPortable/Utils/IFileSystemWatcherAPIs.cs
LibTVRefCommonPortable/Utils/IPackageManager.cs
LibTVRefCommonPortable/Utils/IPlatformNotification.cs
LibTVRefCommonPortable/Utils/ITVHome.cs
LibTVRefCommonPortable/Utils/IWifiAPIs.cs
LibTVRefCommonPortable/Utils/PackageManagerUtils.cs
LibTVRefCommonPortable/Utils/RecentShortcutStorage.cs
LibTVRefCommonPortable/Utils/TVHomeImpl.cs
LibTVRefCommonTizen/Ports/AppControlPort.cs
LibTVRefCommonTizen/Ports/ApplicationManagerPort.cs
LibTVRefCommonTizen/Ports/DBPort.cs
LibTVRefCommonTizen/Ports/FileSystemPort.cs
LibTVRefCommonTizen/Ports/FileSystemWatcherPort.cs
LibTVRefCommonTizen/Ports/PackageManagerPort.cs
TVHome/TVHome/Controls/MainPanelButton.xaml
TVHome/TVHome/Controls/MainPanelButton.xaml.cs
TVHome/TVHome/Controls/PanelButton.cs
TVHome/TVHome/Controls/SubPanelAllAppsButton.xaml
TVHome/TVHome/Controls/SubPanelAllAppsButton.xaml.cs
TVHome/TVHome/Controls/SubPanelButton.xaml
TVHome/TVHome/Controls/SubPanelButton.xaml.cs
TVHome/TVHome/Controls/SubPanelReservedButton.xaml
TVHome/TVHome/Controls/SubPanelReservedButton.xaml.cs
TVHome/TVHome/Controls/SubPanelThumbnailButton.xaml
TVHome/TVHome/Controls/SubPanelThumbnailButton.xaml.cs
TVHome/TVHome/ViewModels/MainPageViewModel.cs
TVHome/TVHome/Views/MainPage.xaml
TVHome/TVHome/Views/MainPage.xaml.cs
TVHome/TVHome/Views/MainPanel.xaml
TVHome/TVHome/Views/MainPanel.xaml.cs
TVHome/TVHome/Views/Panel.cs
TVHome/TVHome/Views/SubPanel.xaml
TVHome/TVHome/Views/SubPanel.xaml.cs
TVHome/TVHome/Views/SubThumbnailPanel.xaml
TVHome/TVHome/Views/SubThumbnailPanel.xaml.cs

index 6bff0dd99bdb84f1358365543300521908577bd4..dedc3d72f8a0a674c3692fd44ec6e460cd5ebd4c 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index ac10c501c38df0143776d961f3cd67700e0d5aca..e6f24ee8e00b47a7b03ee4bb42f4829df857a124 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index b49b73f0f1f02023506bc244138f1829dfa02695..3ad03a31f113ca44d46d7b7834faf1ddc0fdfe5d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 589fea0c717412135c3f5350292fd16aafffa239..3295754ca36c8bd3441c47abc260d9ea6213a281 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 628f158f04f4f2b0b6f6607e49de694dba1a603b..d83466461e15fa0db226eec8930da22fb9c017e4 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index db3938e7836634deeb13f2c3235f54b1b810b141..1c8baabbfa1d312fe96c98f579596ccd2ad9b987 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 6209f2c10aa868a90c6f9212267558f215f5ea48..a4141fdda1261b061335a82e18b36ed74e1118c0 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 4f4870035f118c46d401438caf85d13abef2e6fc..2ec5f72b9d2842071c3090d20f2e0e6c28fb420d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index d6c159fa72a0151c8bd6cf6964755fee5f11e3da..751295365abcddef47b4bef6393e136f60bcd4f3 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 79222ed686c16896bfc71eadc800650e609eb5d3..cd3ddb8a03db2f50bbe134b9dba814773eea5c0d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index b6a37fca738400e9ce0997b95272d5146fbb96b7..4ce2dc66a8e0a286bfc5662f2ee9ac1525612028 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 92770f2a2aab8d1c4be73411ecd1bd365a5e23a8..3fea4a3ee0613ff70d2bf4c35fee9146c022c41d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index dda174f06b7e05d6c61771c55de41bf970994c97..efcfd2b0c392567e2ddf842db0043501cd9f7bed 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 48eefad48a65eff80f5deb255d9e8535961cd712..f1c21abdf12255bbda6e9efcd4f05f4bb32125b3 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 07e24db7a33b5cbfe5025ce9061c406f30941eaf..0d227d109983c7f12bde8a839913fbc7d20b0505 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 7bd2ab6d7ac524b51b31342f346d2a45e83a8f33..7c283e91bc0821a98b1edf5617d792786d5f6f7a 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 89244f2ec24bd7cfcd8a377cb7b961331953a861..c7f0fa4d2576a95a58733fdb30a4308046cedbf1 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 05d5c651073b05d1d7775f5d9c035ad27ecca051..b09588c405de88e02ba0730aab7c4e536eabb96c 100644 (file)
@@ -1,4 +1,4 @@
-namespace LibTVRefCommonPortable.DataModels
+namespace LibTVRefCommonPortable.DataModels
 {
     public enum WatcherType
     {
index 956c564fcec7ea7e58644f4c5fadc1d9b17a25d1..aabe064a13dd2839119f3bc294213741b612928b 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 9ece2e22e97675c49325bc05e7bd9d0689ecb5a6..f36d316d1b019fcd9d5d5663807ad5fd4c4929f3 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 9576414b21996da9dce8980d26b40fc4513958bd..d2e760d49f329d3aba72361c29e73b5b7dc9ad20 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 5fbe6793c1958664afbb9e916a171be0cac6c59c..846de6212ea4d9e557fcf2139980997d2632092d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 9ec16a6abe890cf980a591a53fe606d81ca1e122..af468a74d2929b77394691b301959222c601f9d8 100644 (file)
@@ -1,4 +1,4 @@
-using System;
+using System;
 using System.Collections.Generic;
 using System.Linq;
 using System.Text;
index 820dcadcfbcb7f3bcb84d96d23973a6c0a2523d9..de8edff876b9f5204cad8e3616c30598070ba4a3 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 264020dba6f52b376ddae66015bfd069f71c5932..300ba08473c76e74f743ff51a26960f83cb53a4c 100644 (file)
-/*\r
- * Copyright (c) 2017 Samsung Electronics Co., Ltd\r
- *\r
- * Licensed under the Flora License, Version 1.1 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- *     http://floralicense.org/license/\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- */\r
-\r
-using System;\r
-using System.Collections;\r
-using System.Collections.Generic;\r
-using System.Threading.Tasks;\r
-using LibTVRefCommonPortable.DataModels;\r
-using LibTVRefCommonPortable.Utils;\r
-\r
-using Xamarin.Forms;\r
-\r
-namespace LibTVRefCommonPortable.Models\r
-{\r
-    public class RecentShortcutController\r
-    {\r
-        public RecentShortcutController()\r
-        {\r
-        }\r
-\r
-        public void Remove(RecentShortcutInfo history)\r
-        {\r
-            RecentShortcutStorage.Delete(history);\r
-        }\r
-\r
-        public void RemoveAll()\r
-        {\r
-            RecentShortcutStorage.DeleteAll();\r
-        }\r
-\r
-        public bool Update(RecentShortcutInfo shortcut)\r
-        {\r
-            RecentShortcutStorage.Update(shortcut);\r
-            return false;\r
-        }\r
-\r
-        public IEnumerable<RecentShortcutInfo> GetList()\r
-        {\r
-            // TODO : This is a clone of AppShorcutController.ReadFromFile(). Write new code by using RUA\r
-            IEnumerable<AppShortcutInfo> pinned_apps_info = AppShortcutStorage.Read();\r
-            IApplicationManagerAPIs applicationManagerPort = DependencyService.Get<IApplicationManagerAPIs>();\r
-            List<RecentShortcutInfo> recentShortcutInfoList = new List<RecentShortcutInfo>();\r
-            string[] icons = { "ic_black.png", "ic_blue.png", "ic_green.png", "ic_red.png", "ic_yellow.png", "AppIcon.png" };\r
-\r
-            foreach (AppShortcutInfo appShortcutInfo in pinned_apps_info)\r
-            {\r
-                Dictionary<string, string> appInfo = applicationManagerPort.GetInstalledApplication(appShortcutInfo.AppID);\r
-\r
-                if (appInfo != null)\r
-                {\r
-                    string appLabel;\r
-                    string appIconPath;\r
-\r
-                    appInfo.TryGetValue("Label", out appLabel);\r
-                    appInfo.TryGetValue("IconPath", out appIconPath);\r
-\r
-                    Random random = new Random();\r
-                    var defaultStateDescription = new StateDescription()\r
-                    {\r
-                        Label = appLabel,\r
-                        IconPath = appIconPath ?? icons[random.Next(0, 6)],\r
-                        Action = new AppControlAction\r
-                        {\r
-                            AppID = appShortcutInfo.AppID,\r
-                        }\r
-                    };\r
-                    var newRecentShortcutInfo = new RecentShortcutInfo();\r
-                    newRecentShortcutInfo.ScreenshotPath = "screenshot.png";\r
-                    // newRecentShortcutInfo.ScreenshotPath = "screenshot_" + appShortcutInfo.AppID + ".png";\r
-                    newRecentShortcutInfo.StateDescriptions.Add("default", defaultStateDescription);\r
-                    newRecentShortcutInfo.CurrentStateDescription = defaultStateDescription;\r
-                    recentShortcutInfoList.Add(newRecentShortcutInfo);\r
-                }\r
-            }\r
-\r
-            return recentShortcutInfoList;\r
-        }\r
-\r
-        public async Task<IEnumerable<RecentShortcutInfo>> GetListAsync()\r
-        {\r
-            IApplicationManagerAPIs applicationManagerPort = DependencyService.Get<IApplicationManagerAPIs>();\r
-            List<RecentShortcutInfo> recentShortcutInfoList = new List<RecentShortcutInfo>();\r
-\r
-            var applicationList = await applicationManagerPort.GetRecentApplications();\r
-            foreach (KeyValuePair<string, string[]> item in applicationList)\r
-            {\r
-                var defaultStateDescription = new StateDescription()\r
-                {\r
-                    Label = item.Value[0],\r
-                    IconPath = item.Value[2],\r
-                    Action = new AppControlAction()\r
-                    {\r
-                        AppID = item.Key\r
-                    }\r
-                };\r
-                var recentShortcutInfo = new RecentShortcutInfo();\r
-                recentShortcutInfo.ScreenshotPath = "screenshot_" + item.Value[0] + ".png";\r
-                recentShortcutInfo.StateDescriptions.Add("default", defaultStateDescription);\r
-                recentShortcutInfo.CurrentStateDescription = defaultStateDescription;\r
-                recentShortcutInfoList.Add(recentShortcutInfo);\r
-            }\r
-\r
-            return recentShortcutInfoList;\r
-\r
-        }\r
-    }\r
-}\r
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections;
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using LibTVRefCommonPortable.DataModels;
+using LibTVRefCommonPortable.Utils;
+
+using Xamarin.Forms;
+
+namespace LibTVRefCommonPortable.Models
+{
+    public class RecentShortcutController
+    {
+        public RecentShortcutController()
+        {
+        }
+
+        public void Remove(RecentShortcutInfo history)
+        {
+            RecentShortcutStorage.Delete(history);
+        }
+
+        public void RemoveAll()
+        {
+            RecentShortcutStorage.DeleteAll();
+        }
+
+        public bool Update(RecentShortcutInfo shortcut)
+        {
+            RecentShortcutStorage.Update(shortcut);
+            return false;
+        }
+
+        public IEnumerable<RecentShortcutInfo> GetList()
+        {
+            // TODO : This is a clone of AppShorcutController.ReadFromFile(). Write new code by using RUA
+            IEnumerable<AppShortcutInfo> pinned_apps_info = AppShortcutStorage.Read();
+            IApplicationManagerAPIs applicationManagerPort = DependencyService.Get<IApplicationManagerAPIs>();
+            List<RecentShortcutInfo> recentShortcutInfoList = new List<RecentShortcutInfo>();
+            string[] icons = { "ic_black.png", "ic_blue.png", "ic_green.png", "ic_red.png", "ic_yellow.png", "AppIcon.png" };
+
+            foreach (AppShortcutInfo appShortcutInfo in pinned_apps_info)
+            {
+                Dictionary<string, string> appInfo = applicationManagerPort.GetInstalledApplication(appShortcutInfo.AppID);
+
+                if (appInfo != null)
+                {
+                    string appLabel;
+                    string appIconPath;
+
+                    appInfo.TryGetValue("Label", out appLabel);
+                    appInfo.TryGetValue("IconPath", out appIconPath);
+
+                    Random random = new Random();
+                    var defaultStateDescription = new StateDescription()
+                    {
+                        Label = appLabel,
+                        IconPath = appIconPath ?? icons[random.Next(0, 6)],
+                        Action = new AppControlAction
+                        {
+                            AppID = appShortcutInfo.AppID,
+                        }
+                    };
+                    var newRecentShortcutInfo = new RecentShortcutInfo();
+                    newRecentShortcutInfo.ScreenshotPath = "screenshot.png";
+                    // newRecentShortcutInfo.ScreenshotPath = "screenshot_" + appShortcutInfo.AppID + ".png";
+                    newRecentShortcutInfo.StateDescriptions.Add("default", defaultStateDescription);
+                    newRecentShortcutInfo.CurrentStateDescription = defaultStateDescription;
+                    recentShortcutInfoList.Add(newRecentShortcutInfo);
+                }
+            }
+
+            return recentShortcutInfoList;
+        }
+
+        public async Task<IEnumerable<RecentShortcutInfo>> GetListAsync()
+        {
+            IApplicationManagerAPIs applicationManagerPort = DependencyService.Get<IApplicationManagerAPIs>();
+            List<RecentShortcutInfo> recentShortcutInfoList = new List<RecentShortcutInfo>();
+
+            var applicationList = await applicationManagerPort.GetRecentApplications();
+            foreach (KeyValuePair<string, string[]> item in applicationList)
+            {
+                var defaultStateDescription = new StateDescription()
+                {
+                    Label = item.Value[0],
+                    IconPath = item.Value[2],
+                    Action = new AppControlAction()
+                    {
+                        AppID = item.Key
+                    }
+                };
+                var recentShortcutInfo = new RecentShortcutInfo();
+                recentShortcutInfo.ScreenshotPath = "screenshot_" + item.Value[0] + ".png";
+                recentShortcutInfo.StateDescriptions.Add("default", defaultStateDescription);
+                recentShortcutInfo.CurrentStateDescription = defaultStateDescription;
+                recentShortcutInfoList.Add(recentShortcutInfo);
+            }
+
+            return recentShortcutInfoList;
+
+        }
+    }
+}
index 87a98a1bc8b233a9f9ce014fad8b50f6831835e4..e899de714674b432f9a573555708c06e3873c56c 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 234192ff00029f4049b9eacf8bce1056b143b571..143758a6c41799194d37b9024773d17e5ea85689 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 55d908f94cfd2df62da7f4900bdc060cc887b3ea..91952642937f3b2528b1fd929ca57e67558b44e5 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 50cc54e9210175dc23010891a4c10e6b99995b7a..87dbe5e948315c2470e4bea5e54b5d44c77dd2d1 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 54c6f1348df4152bef4ffa8dd0fabcbba9030672..2c5701b52533ed777f9e466914ef45bb9390eba5 100644 (file)
@@ -1,4 +1,4 @@
-using System;
+using System;
 using System.Runtime.InteropServices;
 
 namespace TVHome.Utils
index d170de32d671e928c9116e0612ff6f918e648808..ec57eb2b8a83e871993c52fecc4b91f25bfc375b 100644 (file)
@@ -1,4 +1,4 @@
-using System;
+using System;
 using System.Collections.Generic;
 using System.Linq;
 using System.Text;
index 5964220b1c11f82869278cef8c805f15740861c2..8ee0563245f91cc51ea0fc68da64455628ceeb90 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 30642ffdd059b2e67e12d2f9aa017a6912ea91d3..127658f5b23d7b60e23362e075c032d37235b99f 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index fa52ff27b071a80fd82adc247231f761727c96a8..df1c36934dda12be34efe57bd874ac330d2b20fb 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index d6408ca105eae71dbac23dabd50b5b57a805b1ee..a1781a5590213ad4b0444673e692bea4795c4cc7 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 32d7f36b00382bd1fc53a20f1abb0f4294b34aed..2026e3a64cdce104613a082ceb534dd4eaf40c5e 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 782d4cf45130ddf9700cc13b7f382679a8562781..0b8c138c43ea2b025e890b3bb3478299a9e2c041 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 3b93903b845cba3e8d84226c399ecb0f32f91f24..2555da1315923115099942c3c2a8424eb4ed39f9 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index c5e0a1734bcb79c5fde1fc290c2eeb94162dce79..0e1a5b92748087ba5d61b5c7b236345db1bc6519 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 514037e7686906b05d375db44ee2f5cf9ddf95b8..25b4e89c64c123c8eccb027b2d8e81bf7f2cf743 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 3a8c2e1303ac8b368f734ec4f861a1f520bbde81..19f1f5d0a94af9d62f6e5cfc9bfc1fc73dfae11f 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 64706769561e29ddb9841ac83384b4ee27c27e50..f19ecd4c00f6473cfa1d8b11ace5505245f76e1f 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 50da8700bf049512efb93febf5b2da6ce4834a6a..5a45de6132b5b9b396177e1e25cdb50ca564b6ee 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 1a23898008a06437a369f8d30a20fed5331eee8c..4123e6c6fd8b633a84e4653afc11c1a8fe8912d7 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 292141a449df6a6d2708c2cd0497993659ee316a..adfb8f5b97e02c68e7a432b765a17f69d8942b5b 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 74ee416e166b5d589f688268718299270075046d..060c35061bbbf10517a0528a86cfef40de50d329 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index cf4b395d8224a9749757d017a9adc0df9015b70c..f5022f04b30d4e8655e0d49aa669f857799b00ff 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index d6b9c55a9b92a51c9e07d7498fa067f18bdd7568..b0ed1bf84e8332ab04fa6cc1deb3e0d2f7d7c408 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 426fcb1cd7213ee464c630ed534a54744b3bd69a..590061778826d2e8c45267b2616ed8e2730324bd 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 9ce24efaec5fde65eb4cda0bc97a297ede3bbe83..6c15e1b4813a8e346cb25daafd9f45539a35a4ee 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 792acff62d7f84399a713e1a3805ff3ad3eb8972..72717babae331459990aa850aa79952839a8620d 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 375931d06ea7d8f1b6cef2c7bf1e42ca1ea6ca90..b21db6fa96e8d2368c6084b1d861b07e4c48eb14 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index bc040b0af7b89c426f770b1629116fb53cb92f02..fd0ae29116d00c6fde8e1a3b84fc83658fbbeb97 100755 (executable)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"
                       xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                       xmlns:Controls="clr-namespace:TVHome.Controls"
index 0167de52f760cbc4f688890a3b84e17ede718dd0..c3841a85143f79a8eb6c13f88763ab722427d82f 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index e68c701e6ea757a58cc9fff1e2bf99cf73260238..2472f77bacc7bfe55d98e061d145d70de249350d 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index ac75fd9b9e6d2021d303999356cc2d0ef406d471..4ca050a6d2520c5b8b415795fb7d79d055c5b519 100755 (executable)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"
                       xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                       xmlns:Controls="clr-namespace:TVHome.Controls"
index 97ace97cadb09eb1d279c873c3b2af568ef4844c..f9f8e5ed89eb66bc6c3d1b2f52a24b2ba3797560 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 137b5da0d8fdf3043b07f0a2f5b09eec4375628e..ac2cbdb06cbb9850918a7adb60365923e5fd426e 100755 (executable)
@@ -1,43 +1,43 @@
-<?xml version="1.0" encoding="UTF-8"?>\r
-<Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"\r
-                      xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"\r
-                      xmlns:Controls="clr-namespace:TVHome.Controls"\r
-                      x:Class="TVHome.Controls.SubPanelButton">\r
-    <RelativeLayout x:Name="ButtonBox"\r
-                 WidthRequest="138"\r
-                 HeightRequest="186"\r
-                 HorizontalOptions="Center">\r
-        <Image x:Name="ButtonImage"\r
-               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"\r
-               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0}"\r
-               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.7419}"\r
-               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"\r
-               Source="{Binding CurrentStateDescription.IconPath}" />\r
-      <Image x:Name="ButtonDimmedImage"\r
-               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Width, Factor=0}"\r
-               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Height, Factor=0}"\r
-               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Height, Factor=1}"\r
-               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Width, Factor=1}"\r
-               Source="img_tizen_home_list_dim_apps.png" />\r
-        <Label x:Name="ButtonTitle"\r
-               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"\r
-               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.8387}"\r
-               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.1613}"\r
-               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"\r
-               Opacity="0.6"\r
-               TextColor="White"\r
-               FontSize="52"\r
-               LineBreakMode="TailTruncation"\r
-               HorizontalTextAlignment="Center"\r
-               Text="{Binding CurrentStateDescription.Label}" />\r
-        <Button x:Name = "ButtonFocusArea"\r
-               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"\r
-               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0}"\r
-               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=1}"\r
-               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"\r
-                Focused="OnFocused"\r
-                Unfocused="OnUnfocused"\r
-                Clicked="OnClicked"\r
-                Opacity="0" />\r
-    </RelativeLayout>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"
+                      xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
+                      xmlns:Controls="clr-namespace:TVHome.Controls"
+                      x:Class="TVHome.Controls.SubPanelButton">
+    <RelativeLayout x:Name="ButtonBox"
+                 WidthRequest="138"
+                 HeightRequest="186"
+                 HorizontalOptions="Center">
+        <Image x:Name="ButtonImage"
+               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"
+               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0}"
+               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.7419}"
+               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"
+               Source="{Binding CurrentStateDescription.IconPath}" />
+      <Image x:Name="ButtonDimmedImage"
+               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Width, Factor=0}"
+               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Height, Factor=0}"
+               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Height, Factor=1}"
+               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonImage, Property=Width, Factor=1}"
+               Source="img_tizen_home_list_dim_apps.png" />
+        <Label x:Name="ButtonTitle"
+               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"
+               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.8387}"
+               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0.1613}"
+               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"
+               Opacity="0.6"
+               TextColor="White"
+               FontSize="52"
+               LineBreakMode="TailTruncation"
+               HorizontalTextAlignment="Center"
+               Text="{Binding CurrentStateDescription.Label}" />
+        <Button x:Name = "ButtonFocusArea"
+               RelativeLayout.XConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=0}"
+               RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=0}"
+               RelativeLayout.HeightConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Height, Factor=1}"
+               RelativeLayout.WidthConstraint="{ConstraintExpression Type=RelativeToView, ElementName=ButtonBox, Property=Width, Factor=1}"
+                Focused="OnFocused"
+                Unfocused="OnUnfocused"
+                Clicked="OnClicked"
+                Opacity="0" />
+    </RelativeLayout>
 </Controls:PanelButton>
\ No newline at end of file
index 1e309eec29c3e40708a88e68ac774071afa99c85..8022fc564ddb26102b684baf6633524d50aac1d3 100755 (executable)
@@ -1,67 +1,67 @@
-/*\r
- * Copyright (c) 2017 Samsung Electronics Co., Ltd\r
- *\r
- * Licensed under the Flora License, Version 1.1 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- *     http://floralicense.org/license/\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- */\r
-\r
-using System;\r
-using System.Windows.Input;\r
-using LibTVRefCommonPortable.Utils;\r
-using Xamarin.Forms;\r
-\r
-namespace TVHome.Controls\r
-{\r
-    /// <summary>\r
-    /// Custom Control for Button in Sub Panel\r
-    /// </summary>\r
-    public partial class SubPanelButton : PanelButton\r
-    {\r
-        public SubPanelButton()\r
-        {\r
-            InitializeComponent();\r
-        }\r
-\r
-        public override async void OnClicked(object sender, EventArgs e)\r
-        {\r
-            if (OnClickedCommand != null)\r
-            {\r
-                OnClickedCommand.Execute("");\r
-            }\r
-\r
-            await View.FadeTo(0.99, 300);\r
-        }\r
-\r
-        public override async void OnFocused(object sender, FocusEventArgs e)\r
-        {\r
-            if (OnFocusedCommand != null)\r
-            {\r
-                OnFocusedCommand.Execute("");\r
-            }\r
-\r
-#pragma warning disable CS4014\r
-            ButtonTitle.FadeTo(0.99, 300);\r
-            ButtonTitle.TranslateTo(0, 22, 300);\r
-#pragma warning restore CS4014\r
-            await ButtonImage.ScaleTo(1.3, 300);\r
-        }\r
-\r
-        public override async void OnUnfocused(object sender, FocusEventArgs e)\r
-        {\r
-#pragma warning disable CS4014\r
-            ButtonTitle.FadeTo(0.5, 300);\r
-            ButtonTitle.TranslateTo(0, 0, 300);\r
-#pragma warning restore CS4014\r
-            await ButtonImage.ScaleTo(1, 300);\r
-        }\r
-    }\r
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Windows.Input;
+using LibTVRefCommonPortable.Utils;
+using Xamarin.Forms;
+
+namespace TVHome.Controls
+{
+    /// <summary>
+    /// Custom Control for Button in Sub Panel
+    /// </summary>
+    public partial class SubPanelButton : PanelButton
+    {
+        public SubPanelButton()
+        {
+            InitializeComponent();
+        }
+
+        public override async void OnClicked(object sender, EventArgs e)
+        {
+            if (OnClickedCommand != null)
+            {
+                OnClickedCommand.Execute("");
+            }
+
+            await View.FadeTo(0.99, 300);
+        }
+
+        public override async void OnFocused(object sender, FocusEventArgs e)
+        {
+            if (OnFocusedCommand != null)
+            {
+                OnFocusedCommand.Execute("");
+            }
+
+#pragma warning disable CS4014
+            ButtonTitle.FadeTo(0.99, 300);
+            ButtonTitle.TranslateTo(0, 22, 300);
+#pragma warning restore CS4014
+            await ButtonImage.ScaleTo(1.3, 300);
+        }
+
+        public override async void OnUnfocused(object sender, FocusEventArgs e)
+        {
+#pragma warning disable CS4014
+            ButtonTitle.FadeTo(0.5, 300);
+            ButtonTitle.TranslateTo(0, 0, 300);
+#pragma warning restore CS4014
+            await ButtonImage.ScaleTo(1, 300);
+        }
+    }
 }
\ No newline at end of file
index 4eb4d7c9471c7bb98a7ecd5bf48e20ddd50c8dca..cc9e32d1ffd3c873f8782944345df5bbf9b1607c 100755 (executable)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"
                       xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                       xmlns:Controls="clr-namespace:TVHome.Controls"
index 106085a7707e7a6feca2a70eccb3a01abebca1bd..793fd4adfe699ec1a01908a29d1ea0cbf4cb5e80 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 9871755032e7973436d996597c962bd26b90c1de..b38148a040acbc0c50a1457ace64b48c17ad1102 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <Controls:PanelButton xmlns="http://xamarin.com/schemas/2014/forms"
                       xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                       xmlns:Controls="clr-namespace:TVHome.Controls"
index f523478b1318293b67a9c9b9adbd8727b45e9916..e8e220a33a5507c9c744242a0c0bafebe12b4218 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index a809017ae2ee44de3d5783bb6a0ec2d6323a46cb..1576ac7ff048544c1bfdf1080651bd63893f1037 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index f4ede16df28c33190236f2209f4eab20781728cc..2ccca478c75e1da61ad2fca242f46e6b897cc249 100755 (executable)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8" ?>
+<?xml version="1.0" encoding="utf-8" ?>
 <ContentPage x:Class="TVHome.Views.MainPage"
              xmlns="http://xamarin.com/schemas/2014/forms"
              xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
index 57878895db6707903bb01cd6d1a16f0c640aadc4..e3db19bf7684f3ebe548afbb137c26084bc36aad 100755 (executable)
-/*\r
- * Copyright (c) 2017 Samsung Electronics Co., Ltd\r
- *\r
- * Licensed under the Flora License, Version 1.1 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- *     http://floralicense.org/license/\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- */\r
-\r
-using System;\r
-using System.Collections.Generic;\r
-using System.Diagnostics;\r
-using System.Windows.Input;\r
-using LibTVRefCommonPortable.DataModels;\r
-using LibTVRefCommonPortable.Models;\r
-using LibTVRefCommonPortable.Utils;\r
-using Xamarin.Forms;\r
-\r
-namespace TVHome.Views\r
-{\r
-    /// <summary>\r
-    /// Root Page of Application\r
-    /// </summary>\r
-    public partial class MainPage : ContentPage\r
-    {\r
-\r
-        private Dictionary<string, Panel> SubPanelDictionary;\r
-        private Panel currentSubPanel;\r
-        public ICommand ChangeSubPanelCommand;\r
-\r
-        public MainPage()\r
-        {\r
-            InitializeComponent();\r
-            SubPanelDictionary = new Dictionary<string, Panel>();\r
-            SubPanelDictionary.Add("Recent", RecentSubPanel);\r
-            SubPanelDictionary.Add("Apps", AppsSubPanel);\r
-            SubPanelDictionary.Add("Settings", SettingsSubPanel);\r
-\r
-            PageMainPanel.OnFocusedCommand = new Command<string>((key) =>\r
-            {\r
-                DebuggingUtils.Dbg("MainPage : " + key);\r
-                if (currentSubPanel != null)\r
-                {\r
-                    currentSubPanel.HidePanel();\r
-                }\r
-\r
-                currentSubPanel = SubPanelDictionary[key];\r
-                currentSubPanel.ShowPanel();\r
-            });\r
-\r
-            RecentSubPanel.OnFocusedCommand = new Command(() =>\r
-            {\r
-                PageMainPanel.SelectPanel();\r
-            });\r
-\r
-            AppsSubPanel.OnFocusedCommand = new Command(() =>\r
-            {\r
-                PageMainPanel.SelectPanel();\r
-            });\r
-\r
-            AppsSubPanel.OnUnpinCommand = new Command<string>((appId) =>\r
-            {\r
-                UnpinAppShortcutInfo(appId);\r
-            });\r
-\r
-            SettingsSubPanel.OnFocusedCommand = new Command(() =>\r
-            {\r
-                PageMainPanel.SelectPanel();\r
-            });\r
-        }\r
-\r
-        private void OnAppearing(object sender, EventArgs e)\r
-        {\r
-            PageMainPanel.InitialFocusing();\r
-        }\r
-\r
-        private void UnpinAppShortcutInfo(string appId)\r
-        {\r
-            RemovePinnedApp(appId);\r
-        }\r
-\r
-        private void UpdatePinnedApps(Dictionary<string, string> PinnedApps)\r
-        {\r
-            List<AppShortcutInfo> pinnedAppList = new List<AppShortcutInfo>();\r
-            foreach (var item in PinnedApps)\r
-            {\r
-                pinnedAppList.Add(new AppShortcutInfo()\r
-                {\r
-                    AppID = item.Key,\r
-                });\r
-            }\r
-\r
-            TVHomeImpl.GetInstance.AppShortcutControllerInstance.UpdatePinnedApps(pinnedAppList);\r
-        }\r
-\r
-        public void RemovePinnedApp(string AppID)\r
-        {\r
-            Dictionary<string, string> PinnedApps = TVHomeImpl.GetInstance.AppShortcutControllerInstance.GetPinnedAppsAppIDs();\r
-            if (PinnedApps.ContainsKey(AppID))\r
-            {\r
-                PinnedApps.Remove(AppID);\r
-                UpdatePinnedApps(PinnedApps);\r
-            }\r
-        }\r
-    }\r
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.Diagnostics;
+using System.Windows.Input;
+using LibTVRefCommonPortable.DataModels;
+using LibTVRefCommonPortable.Models;
+using LibTVRefCommonPortable.Utils;
+using Xamarin.Forms;
+
+namespace TVHome.Views
+{
+    /// <summary>
+    /// Root Page of Application
+    /// </summary>
+    public partial class MainPage : ContentPage
+    {
+
+        private Dictionary<string, Panel> SubPanelDictionary;
+        private Panel currentSubPanel;
+        public ICommand ChangeSubPanelCommand;
+
+        public MainPage()
+        {
+            InitializeComponent();
+            SubPanelDictionary = new Dictionary<string, Panel>();
+            SubPanelDictionary.Add("Recent", RecentSubPanel);
+            SubPanelDictionary.Add("Apps", AppsSubPanel);
+            SubPanelDictionary.Add("Settings", SettingsSubPanel);
+
+            PageMainPanel.OnFocusedCommand = new Command<string>((key) =>
+            {
+                DebuggingUtils.Dbg("MainPage : " + key);
+                if (currentSubPanel != null)
+                {
+                    currentSubPanel.HidePanel();
+                }
+
+                currentSubPanel = SubPanelDictionary[key];
+                currentSubPanel.ShowPanel();
+            });
+
+            RecentSubPanel.OnFocusedCommand = new Command(() =>
+            {
+                PageMainPanel.SelectPanel();
+            });
+
+            AppsSubPanel.OnFocusedCommand = new Command(() =>
+            {
+                PageMainPanel.SelectPanel();
+            });
+
+            AppsSubPanel.OnUnpinCommand = new Command<string>((appId) =>
+            {
+                UnpinAppShortcutInfo(appId);
+            });
+
+            SettingsSubPanel.OnFocusedCommand = new Command(() =>
+            {
+                PageMainPanel.SelectPanel();
+            });
+        }
+
+        private void OnAppearing(object sender, EventArgs e)
+        {
+            PageMainPanel.InitialFocusing();
+        }
+
+        private void UnpinAppShortcutInfo(string appId)
+        {
+            RemovePinnedApp(appId);
+        }
+
+        private void UpdatePinnedApps(Dictionary<string, string> PinnedApps)
+        {
+            List<AppShortcutInfo> pinnedAppList = new List<AppShortcutInfo>();
+            foreach (var item in PinnedApps)
+            {
+                pinnedAppList.Add(new AppShortcutInfo()
+                {
+                    AppID = item.Key,
+                });
+            }
+
+            TVHomeImpl.GetInstance.AppShortcutControllerInstance.UpdatePinnedApps(pinnedAppList);
+        }
+
+        public void RemovePinnedApp(string AppID)
+        {
+            Dictionary<string, string> PinnedApps = TVHomeImpl.GetInstance.AppShortcutControllerInstance.GetPinnedAppsAppIDs();
+            if (PinnedApps.ContainsKey(AppID))
+            {
+                PinnedApps.Remove(AppID);
+                UpdatePinnedApps(PinnedApps);
+            }
+        }
+    }
 }
\ No newline at end of file
index b881fff0cefd23691cfbe26312eef57c34db3fd2..53663d05b0f2f25f72a2c20d7fa5709a7ab2d0e3 100644 (file)
@@ -1,13 +1,13 @@
-<?xml version="1.0" encoding="UTF-8"?>\r
-<Views:Panel xmlns="http://xamarin.com/schemas/2014/forms"\r
-             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"\r
-             xmlns:Views="clr-namespace:TVHome.Views"\r
-             x:Class="TVHome.Views.MainPanel">\r
-    <Grid x:Name="PanelButtonGrid">\r
-        <Grid.ColumnDefinitions>\r
-            <ColumnDefinition Width="1*" />\r
-            <ColumnDefinition Width="1*" />\r
-            <ColumnDefinition Width="1*" />\r
-        </Grid.ColumnDefinitions>\r
-    </Grid>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<Views:Panel xmlns="http://xamarin.com/schemas/2014/forms"
+             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
+             xmlns:Views="clr-namespace:TVHome.Views"
+             x:Class="TVHome.Views.MainPanel">
+    <Grid x:Name="PanelButtonGrid">
+        <Grid.ColumnDefinitions>
+            <ColumnDefinition Width="1*" />
+            <ColumnDefinition Width="1*" />
+            <ColumnDefinition Width="1*" />
+        </Grid.ColumnDefinitions>
+    </Grid>
 </Views:Panel>
\ No newline at end of file
index 76f12fcca43b237616454c6171ffe86ee8a95587..217765185906830be612dfcf933f2f9f1404b8df 100644 (file)
@@ -1,92 +1,92 @@
-/*\r
- * Copyright (c) 2017 Samsung Electronics Co., Ltd\r
- *\r
- * Licensed under the Flora License, Version 1.1 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- *     http://floralicense.org/license/\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- */\r
-\r
-using System;\r
-using System.Collections.Generic;\r
-using System.ComponentModel;\r
-using System.Windows.Input;\r
-using TVHome.Controls;\r
-using LibTVRefCommonPortable.DataModels;\r
-using LibTVRefCommonPortable.Utils;\r
-using TVHome.ViewModels;\r
-using Xamarin.Forms;\r
-\r
-namespace TVHome.Views\r
-{\r
-    /// <summary>\r
-    /// Main Panel in Main Page\r
-    /// </summary>\r
-    public partial class MainPanel : Panel\r
-    {\r
-        public MainPanel()\r
-        {\r
-            InitializeComponent();\r
-            PropertyChanged += OnItemsSourcePropertyChanged;\r
-        }\r
-\r
-        private void OnItemsSourcePropertyChanged(object sender, PropertyChangedEventArgs e)\r
-        {\r
-            if (e.PropertyName != "ItemsSource")\r
-            {\r
-                return;\r
-            }\r
-\r
-            var index = 0;\r
-            PanelButtonGrid.Children.Clear();\r
-            foreach (ShortcutInfo item in ItemsSource)\r
-            {\r
-                var button = new MainPanelButton();\r
-                button.View.BindingContext = item;\r
-                button.OnFocusedCommand = new Command(() =>\r
-                {\r
-                    FocusPanel();\r
-                    OnFocusedCommand.Execute(item.StateDescriptions["default"].Label);\r
-                });\r
-                button.OnClickedCommand = new Command(() =>\r
-                {\r
-                    item.DoAction();\r
-                });\r
-                PanelButtonGrid.Children.Add(button.View, index++, 0);\r
-            }\r
-        }\r
-\r
-        public void InitialFocusing()\r
-        {\r
-            var button = PanelButtonGrid.Children[1];\r
-            button.FindByName<Button>("ButtonFocusArea").Focus();\r
-        }\r
-\r
-        public override async void FocusPanel()\r
-        {\r
-            await PanelButtonGrid.TranslateTo(0, 0);\r
-        }\r
-\r
-        public override async void HidePanel()\r
-        {\r
-            await PanelButtonGrid.ScaleTo(0, 0);\r
-        }\r
-\r
-        public async void SelectPanel()\r
-        {\r
-            await PanelButtonGrid.TranslateTo(0, -78);\r
-        }\r
-\r
-        public override async void ShowPanel()\r
-        {\r
-            await PanelButtonGrid.ScaleTo(1, 0);\r
-        }\r
-    }\r
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Windows.Input;
+using TVHome.Controls;
+using LibTVRefCommonPortable.DataModels;
+using LibTVRefCommonPortable.Utils;
+using TVHome.ViewModels;
+using Xamarin.Forms;
+
+namespace TVHome.Views
+{
+    /// <summary>
+    /// Main Panel in Main Page
+    /// </summary>
+    public partial class MainPanel : Panel
+    {
+        public MainPanel()
+        {
+            InitializeComponent();
+            PropertyChanged += OnItemsSourcePropertyChanged;
+        }
+
+        private void OnItemsSourcePropertyChanged(object sender, PropertyChangedEventArgs e)
+        {
+            if (e.PropertyName != "ItemsSource")
+            {
+                return;
+            }
+
+            var index = 0;
+            PanelButtonGrid.Children.Clear();
+            foreach (ShortcutInfo item in ItemsSource)
+            {
+                var button = new MainPanelButton();
+                button.View.BindingContext = item;
+                button.OnFocusedCommand = new Command(() =>
+                {
+                    FocusPanel();
+                    OnFocusedCommand.Execute(item.StateDescriptions["default"].Label);
+                });
+                button.OnClickedCommand = new Command(() =>
+                {
+                    item.DoAction();
+                });
+                PanelButtonGrid.Children.Add(button.View, index++, 0);
+            }
+        }
+
+        public void InitialFocusing()
+        {
+            var button = PanelButtonGrid.Children[1];
+            button.FindByName<Button>("ButtonFocusArea").Focus();
+        }
+
+        public override async void FocusPanel()
+        {
+            await PanelButtonGrid.TranslateTo(0, 0);
+        }
+
+        public override async void HidePanel()
+        {
+            await PanelButtonGrid.ScaleTo(0, 0);
+        }
+
+        public async void SelectPanel()
+        {
+            await PanelButtonGrid.TranslateTo(0, -78);
+        }
+
+        public override async void ShowPanel()
+        {
+            await PanelButtonGrid.ScaleTo(1, 0);
+        }
+    }
 }
\ No newline at end of file
index 177cb92a6b76f98d6eaa3386cd660b450fb47062..6d781ffb47e2ca6f67767883c1f0ac4d35cfe52b 100755 (executable)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");
index 543ef6b6cf991533796d18428434d7b38352ea6a..2102ea6342a3c8fbea8e18dfe8a908e213c62032 100755 (executable)
@@ -1,15 +1,15 @@
-<?xml version="1.0" encoding="UTF-8"?>\r
-<Views:Panel xmlns="http://xamarin.com/schemas/2014/forms"\r
-             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"\r
-             xmlns:Views="clr-namespace:TVHome.Views"\r
-             x:Class="TVHome.Views.SubPanel">\r
-    <ScrollView x:Name="PanelScrollView"\r
-                Orientation="Horizontal"\r
-                HorizontalOptions="Center">\r
-        <StackLayout x:Name="PanelButtonStack"\r
-                     Orientation="Horizontal"\r
-                     Padding="96,22,96,26"\r
-                     Spacing="78">\r
-        </StackLayout>\r
-    </ScrollView>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<Views:Panel xmlns="http://xamarin.com/schemas/2014/forms"
+             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
+             xmlns:Views="clr-namespace:TVHome.Views"
+             x:Class="TVHome.Views.SubPanel">
+    <ScrollView x:Name="PanelScrollView"
+                Orientation="Horizontal"
+                HorizontalOptions="Center">
+        <StackLayout x:Name="PanelButtonStack"
+                     Orientation="Horizontal"
+                     Padding="96,22,96,26"
+                     Spacing="78">
+        </StackLayout>
+    </ScrollView>
 </Views:Panel>
\ No newline at end of file
index 81e6af6e82d34ca512e3b66b82248eeb15195464..5c4b9e1be1ba91e97751549ad32093f83b3ec91c 100755 (executable)
-/*\r
- * Copyright (c) 2017 Samsung Electronics Co., Ltd\r
- *\r
- * Licensed under the Flora License, Version 1.1 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- *     http://floralicense.org/license/\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- */\r
-\r
-using System;\r
-using System.Collections.Generic;\r
-using System.Windows.Input;\r
-using System.ComponentModel;\r
-using TVHome.Controls;\r
-using LibTVRefCommonPortable.DataModels;\r
-using TVHome.ViewModels;\r
-using Xamarin.Forms;\r
-using LibTVRefCommonPortable.Utils;\r
-\r
-namespace TVHome.Views\r
-{\r
-    /// <summary>\r
-    /// Sub Panel in Main Page\r
-    /// </summary>\r
-    public partial class SubPanel : Panel\r
-    {\r
-        public SubPanel()\r
-        {\r
-            InitializeComponent();\r
-            isFocused = false;\r
-            PropertyChanged += OnItemsSourcePropertyChanged;\r
-        }\r
-\r
-        private void OnItemsSourcePropertyChanged(object sender, PropertyChangedEventArgs e)\r
-        {\r
-            if (e.PropertyName != "ItemsSource")\r
-            {\r
-                return;\r
-            }\r
-\r
-            PanelButtonStack.Children.Clear();\r
-            foreach (ShortcutInfo item in ItemsSource)\r
-            {\r
-                PanelButton button;\r
-\r
-                if (item.StateDescriptions["default"].Label.Equals("All apps")\r
-                    || item.StateDescriptions["default"].Label.Equals("Add pin"))\r
-                {\r
-                    button = new SubPanelAllAppsButton();\r
-                }\r
-                else if (item.StateDescriptions["default"].Label.Equals("Media Hub"))\r
-                {\r
-                    button = new SubPanelReservedButton();\r
-                }\r
-                else\r
-                               {\r
-                    button = new SubPanelButton();\r
-                               }\r
-\r
-                button.View.BindingContext = item;\r
-                button.OnFocusedCommand = new Command(() =>\r
-                {\r
-                    FocusPanel();\r
-                });\r
-                button.OnClickedCommand = new Command(() =>\r
-                {\r
-                    if (item is AppShortcutInfo)\r
-                    {\r
-                        OnUnpinCommand.Execute((item as AppShortcutInfo).AppID);\r
-                    }\r
-                    else\r
-                    {\r
-                        item.DoAction();\r
-                    }\r
-                });\r
-                PanelButtonStack.Children.Add(button.View);\r
-            }\r
-\r
-            if (!isFocused)\r
-            {\r
-                HidePanel();\r
-            }\r
-            else\r
-            {\r
-                isFocused = false;\r
-                FocusPanel();\r
-            }\r
-\r
-        }\r
-\r
-        public override async void HidePanel()\r
-        {\r
-            isFocused = false;\r
-            foreach (var item in PanelButtonStack.Children)\r
-            {\r
-                item.IsEnabled = false;\r
-            }\r
-\r
-#pragma warning disable CS4014\r
-            PanelScrollView.ScrollToAsync(0, 0, true);\r
-            this.TranslateTo(0, 1, 0);\r
-#pragma warning restore CS4014\r
-            await this.FadeTo(0, 0);\r
-        }\r
-\r
-        public override async void ShowPanel()\r
-        {\r
-            isFocused = false;\r
-            foreach (var item in PanelButtonStack.Children)\r
-            {\r
-                item.IsEnabled = true;\r
-                item.FindByName<Image>("ButtonDimmedImage").Opacity = 0.99;\r
-            }\r
-\r
-#pragma warning disable CS4014\r
-            this.TranslateTo(0, 0, 300);\r
-#pragma warning restore CS4014\r
-            await this.FadeTo(0.3, 300);\r
-        }\r
-\r
-        public override async void FocusPanel()\r
-        {\r
-            if (isFocused)\r
-            {\r
-                return;\r
-            }\r
-\r
-            OnFocusedCommand.Execute("");\r
-\r
-            isFocused = true;\r
-            var button = PanelButtonStack.Children[1];\r
-            button.FindByName<Button>("ButtonFocusArea").Focus();\r
-\r
-            foreach (var item in PanelButtonStack.Children)\r
-            {\r
-                item.FindByName<Image>("ButtonDimmedImage").Opacity = 0;\r
-            }\r
-\r
-#pragma warning disable CS4014\r
-            this.TranslateTo(0, -146, 300);\r
-#pragma warning restore CS4014\r
-            await this.FadeTo(0.99, 300);\r
-        }\r
-    }\r
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.Windows.Input;
+using System.ComponentModel;
+using TVHome.Controls;
+using LibTVRefCommonPortable.DataModels;
+using TVHome.ViewModels;
+using Xamarin.Forms;
+using LibTVRefCommonPortable.Utils;
+
+namespace TVHome.Views
+{
+    /// <summary>
+    /// Sub Panel in Main Page
+    /// </summary>
+    public partial class SubPanel : Panel
+    {
+        public SubPanel()
+        {
+            InitializeComponent();
+            isFocused = false;
+            PropertyChanged += OnItemsSourcePropertyChanged;
+        }
+
+        private void OnItemsSourcePropertyChanged(object sender, PropertyChangedEventArgs e)
+        {
+            if (e.PropertyName != "ItemsSource")
+            {
+                return;
+            }
+
+            PanelButtonStack.Children.Clear();
+            foreach (ShortcutInfo item in ItemsSource)
+            {
+                PanelButton button;
+
+                if (item.StateDescriptions["default"].Label.Equals("All apps")
+                    || item.StateDescriptions["default"].Label.Equals("Add pin"))
+                {
+                    button = new SubPanelAllAppsButton();
+                }
+                else if (item.StateDescriptions["default"].Label.Equals("Media Hub"))
+                {
+                    button = new SubPanelReservedButton();
+                }
+                else
+                               {
+                    button = new SubPanelButton();
+                               }
+
+                button.View.BindingContext = item;
+                button.OnFocusedCommand = new Command(() =>
+                {
+                    FocusPanel();
+                });
+                button.OnClickedCommand = new Command(() =>
+                {
+                    if (item is AppShortcutInfo)
+                    {
+                        OnUnpinCommand.Execute((item as AppShortcutInfo).AppID);
+                    }
+                    else
+                    {
+                        item.DoAction();
+                    }
+                });
+                PanelButtonStack.Children.Add(button.View);
+            }
+
+            if (!isFocused)
+            {
+                HidePanel();
+            }
+            else
+            {
+                isFocused = false;
+                FocusPanel();
+            }
+
+        }
+
+        public override async void HidePanel()
+        {
+            isFocused = false;
+            foreach (var item in PanelButtonStack.Children)
+            {
+                item.IsEnabled = false;
+            }
+
+#pragma warning disable CS4014
+            PanelScrollView.ScrollToAsync(0, 0, true);
+            this.TranslateTo(0, 1, 0);
+#pragma warning restore CS4014
+            await this.FadeTo(0, 0);
+        }
+
+        public override async void ShowPanel()
+        {
+            isFocused = false;
+            foreach (var item in PanelButtonStack.Children)
+            {
+                item.IsEnabled = true;
+                item.FindByName<Image>("ButtonDimmedImage").Opacity = 0.99;
+            }
+
+#pragma warning disable CS4014
+            this.TranslateTo(0, 0, 300);
+#pragma warning restore CS4014
+            await this.FadeTo(0.3, 300);
+        }
+
+        public override async void FocusPanel()
+        {
+            if (isFocused)
+            {
+                return;
+            }
+
+            OnFocusedCommand.Execute("");
+
+            isFocused = true;
+            var button = PanelButtonStack.Children[1];
+            button.FindByName<Button>("ButtonFocusArea").Focus();
+
+            foreach (var item in PanelButtonStack.Children)
+            {
+                item.FindByName<Image>("ButtonDimmedImage").Opacity = 0;
+            }
+
+#pragma warning disable CS4014
+            this.TranslateTo(0, -146, 300);
+#pragma warning restore CS4014
+            await this.FadeTo(0.99, 300);
+        }
+    }
 }
\ No newline at end of file
index 2dcd2435e8dbb49cb928a2d5ecb077aa6d9ce184..3faff6dbfdcbcbd75fc6db412274997f0946bd76 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <Views:Panel xmlns="http://xamarin.com/schemas/2014/forms"
              xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
              xmlns:Views="clr-namespace:TVHome.Views"
index 07e5060de94744ab7a9e8995cf02bf50c7a8c20c..449f7289bca7cb42ec30a82a98a707b3569dc8f4 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*
  * Copyright (c) 2017 Samsung Electronics Co., Ltd
  *
  * Licensed under the Flora License, Version 1.1 (the "License");