Fixed Coding rule check
authorHyerim Kim <rimi.kim@samsung.com>
Mon, 5 Jun 2017 09:23:09 +0000 (18:23 +0900)
committerHyerim Kim <rimi.kim@samsung.com>
Mon, 5 Jun 2017 09:23:09 +0000 (18:23 +0900)
Change-Id: I814ab960b9b341f5a017132c5b9dd608b01f043c
Signed-off-by: Hyerim Kim <rimi.kim@samsung.com>
15 files changed:
TVMediaHub/TVMediaHub.Tizen/Models/ContentProvider.cs
TVMediaHub/TVMediaHub.Tizen/Models/ImageProvider.cs
TVMediaHub/TVMediaHub.Tizen/Models/MusicProvider.cs
TVMediaHub/TVMediaHub.Tizen/Models/VideoProvider.cs
TVMediaHub/TVMediaHub.Tizen/ViewModels/ImageTabViewModel.cs
TVMediaHub/TVMediaHub.Tizen/ViewModels/VideoTabViewModel.cs
TVMediaHub/TVMediaHub.Tizen/Views/ImageGroup.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/ImageItem.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/ImageTab.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/ImageViewer.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/SimpleImageViewer.xaml.cs [changed mode: 0644->0755]
TVMediaHub/TVMediaHub.Tizen/Views/VideoGroup.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/VideoItem.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/VideoPlayer.xaml.cs
TVMediaHub/TVMediaHub.Tizen/Views/VideoTab.xaml.cs

index c15c60435fe12d81b9f1dbe788c2609ab96c64fd..672cfd0172fb5610a3ab8211dc28459ba02900aa 100755 (executable)
@@ -52,6 +52,7 @@ namespace TVMediaHub.Tizen.Models
         /// <summary>
         /// An abstract method to determine the availability of the content.
         /// </summary>
+        /// <param name="mediaContent">A media content to be checked the availability</param>
         abstract protected void CheckUnavailableContent(MediaInformationEx mediaContent);
 
         /// <summary>
@@ -304,7 +305,7 @@ namespace TVMediaHub.Tizen.Models
         /// A method for making thumbnail of Media contents.
         /// </summary>
         /// <param name="list">A list of media contents</param>
-        /// <returns></returns>
+        /// <returns>A path of thumbnail</returns>
         public async Task CheckThumbnail(IEnumerable<MediaShortcutInfo> list)
         {
             foreach (var info in list)
index 63f1f5fc62cf5335237229a558729c7314c2f432..7a0cd72dc9b5def61d91364699421b9d3bc0c98a 100755 (executable)
@@ -46,6 +46,7 @@ namespace TVMediaHub.Tizen.Models
         /// <summary>
         /// A method to determine the availability of the content.
         /// </summary>
+        /// <param name="mediaContent">A media content to be checked the availability</param>
         protected override void CheckUnavailableContent(MediaInformationEx mediaContent)
         {
             if (mediaContent.MediaContentInformation.FilePath != null)
index d8741200230c40304305b18fe7c606bc89be8968..381a3217a053180a2dac36706fefc1803382ce93 100755 (executable)
@@ -44,6 +44,7 @@ namespace TVMediaHub.Tizen.Models
         /// <summary>
         /// A method to determine the availability of the content.
         /// </summary>
+        /// <param name="mediaContent">A media content to be checked the availability</param>
         protected override void CheckUnavailableContent(MediaInformationEx mediaContent)
         {
             // TODO : Add unsupported mime type here
index 7417734f7b802a013e7e8a56376545c654cd10a6..ed9ca1bd4d6f2832f010d14012290b8eb3a342e7 100755 (executable)
@@ -47,6 +47,7 @@ namespace TVMediaHub.Tizen.Models
         /// <summary>
         /// A method to determine the availability of the content.
         /// </summary>
+        /// <param name="mediaContent">A media content to be checked the availability</param>
         protected override void CheckUnavailableContent(MediaInformationEx mediaContent)
         {
             // TODO : Add unsupported mime type here
index b36e2e5e28bf44b5330631c4e15053c74e756aa0..90c384ffa3111d914fa0acd2f1adb55fe6a17dc9 100755 (executable)
@@ -466,13 +466,14 @@ namespace TVMediaHub.Tizen.ViewModels
                     SelectedList.Clear();
                     SelectedList.Add(SelectedItem);
                 }
+
                 foreach (var info in SelectedList)
                 {
                     try
                     {
                         File.Delete(info.MediaContentInformation.FilePath);
                     }
-                    catch(Exception exception)
+                    catch (Exception exception)
                     {
                         // TODO: Handling exceptions
                         DbgPort.E("Exception - " + exception.Message);
index 749edca5d919c835e8132d5b6cf3fe3b6982db32..372eb07f77306ddaca4b5ff49fb4942e5b74935f 100755 (executable)
@@ -142,7 +142,8 @@ namespace TVMediaHub.Tizen.ViewModels
         public int CurrentVideoIndex { get; set; }
         public List<MediaInformationEx> PlayList { get; set; }
 
-        public bool IsLastVideo {
+        public bool IsLastVideo
+        {
             get
             {
                 return (PlayList.Count - 1) == CurrentVideoIndex;
@@ -255,13 +256,14 @@ namespace TVMediaHub.Tizen.ViewModels
                     SelectedList.Clear();
                     SelectedList.Add(SelectedItem);
                 }
+
                 foreach (var info in SelectedList)
                 {
                     try
                     {
                         File.Delete(info.MediaContentInformation.FilePath);
                     }
-                    catch(Exception exception)
+                    catch (Exception exception)
                     {
                         // TODO: Handling exceptions
                         DbgPort.E("Exception - " + exception.Message);
@@ -434,6 +436,7 @@ namespace TVMediaHub.Tizen.ViewModels
         /// A method for reading video contents through VideoProvider and updating VideoList
         /// </summary>
         /// <param name="option">A current sort option</param>
+        /// <param name="storageId">A storage id</param>
         private async void ReadVideoList(SortOption option, string storageId = null)
         {
             VideoList.Clear();
index 4a5fe6679ccdc3304059ab4f8aa7c9b00c225f15..f87f44f5bb45643d07bd595f7343ffc6a243a7f7 100755 (executable)
@@ -363,6 +363,7 @@ namespace TVMediaHub.Tizen.Views
                 focusedItem.ShowContextPopup();
                 return true;
             }
+
             return false;
         }
     }
index 856e647dcaf9f249e934252cffbe628ecc342fa5..a3d7c88563aafdf222b4a3ca9fbe563925e0cf05 100755 (executable)
@@ -419,6 +419,7 @@ namespace TVMediaHub.Tizen.Views
                 IsLoaded = true;
             }
         }
+
         public void ShowContextPopup()
         {
             if (!FocusArea.IsFocused)
@@ -429,12 +430,12 @@ namespace TVMediaHub.Tizen.Views
             ContextPopup popup = new ContextPopup();
             popup.Items.Add(new ContextPopupItem("FILE INFO"));
             popup.Items.Add(new ContextPopupItem("DELETE"));
-            popup.SelectedIndexChanged += selectedIndexChanged;
+            popup.SelectedIndexChanged += SelectedIndexChanged;
             popup.Show(this, this.Width / 2, this.Height + SizeUtils.GetHeightSize(72));
 
         }
 
-        private void selectedIndexChanged(object sender, EventArgs e)
+        private void SelectedIndexChanged(object sender, EventArgs e)
         {
             var ctxPopup = sender as ContextPopup;
             switch (ctxPopup.SelectedIndex)
index 00c50dec6a2a20f05a40044163d9f66e86f07290..731d840ba49537260b0939d11f5f438df08c95e9 100755 (executable)
@@ -676,6 +676,7 @@ namespace TVMediaHub.Tizen.Views
             App.MainWindow.KeyUp -= MenuKeyListener;
             App.MainWindow.KeyUngrab(ElmSharp.EvasKeyEventArgs.PlatformMenuButtonName);
         }
+
         private void MenuKeyListener(object sender, ElmSharp.EvasKeyEventArgs e)
         {
             if (e.KeyName.Equals(ElmSharp.EvasKeyEventArgs.PlatformMenuButtonName))
@@ -719,6 +720,7 @@ namespace TVMediaHub.Tizen.Views
                     {
                         DeleteContentCommand?.Execute(item);
                     }
+
                     break;
             }
 
index e0b854af3779ae8f1cfbe42ef45962f132055676..b858412326a950c025139ce423b77fc86fc83202 100755 (executable)
@@ -451,7 +451,7 @@ namespace TVMediaHub.Tizen.Views
         /// <summary>
         /// A method for getting visible image
         /// </summary>
-        /// <returns></returns>
+        /// <returns>The image to be seen</returns>
         private Xamarin.Forms.Image GetVisibleImage()
         {
             Xamarin.Forms.Image visibleImage = null;
@@ -477,7 +477,7 @@ namespace TVMediaHub.Tizen.Views
         /// <summary>
         /// A method for getting invisible image
         /// </summary>
-        /// <returns></returns>
+        /// <returns>The image to be unseen</returns>
         private Xamarin.Forms.Image GetUnVisibleImage()
         {
             Xamarin.Forms.Image unVisibleImage = null;
old mode 100644 (file)
new mode 100755 (executable)
index 27593f9..e404f83
@@ -711,6 +711,7 @@ namespace TVMediaHub.Tizen.Views
         /// <summary>e
         /// A method for hiding control area when timer is over
         /// </summary>
+        /// <param name="state">The status to be set</param>
         private void HideControlAreaHandler(object state)
         {
             SetControlAreaState(ControlAreaState.HIDE);
index 444ff48bde65b41ad6460519509db6bf97128e12..ebc6a723dc59a77c1a9c633aafa610dc9188c0ca 100755 (executable)
@@ -395,11 +395,12 @@ namespace TVMediaHub.Tizen.Views
         /// <returns>If group has a focused video item, true; otherwise, false</returns>
         public bool NotifyMenuKeyPressedToFocusedItem()
         {
-            if(focusedItem != null)
+            if (focusedItem != null)
             {
                 focusedItem.ShowContextPopup();
                 return true;
             }
+
             return false;
         }
     }
index 88c1125437b540d3e9cf9c9b757899a2221052d2..2318310d3d8fba6f21620b430c1eeb81208ed979 100755 (executable)
@@ -459,12 +459,12 @@ namespace TVMediaHub.Tizen.Views
             ContextPopup popup = new ContextPopup();
             popup.Items.Add(new ContextPopupItem("          FILE INFO           "));
             popup.Items.Add(new ContextPopupItem("DELETE"));
-            popup.SelectedIndexChanged += selectedIndexChanged;
-            popup.Show(this, this.Width/2, this.Height + SizeUtils.GetHeightSize(72));
+            popup.SelectedIndexChanged += SelectedIndexChanged;
+            popup.Show(this, this.Width / 2, this.Height + SizeUtils.GetHeightSize(72));
 
         }
 
-        private void selectedIndexChanged(object sender, EventArgs e)
+        private void SelectedIndexChanged(object sender, EventArgs e)
         {
             var ctxPopup = sender as ContextPopup;
             switch (ctxPopup.SelectedIndex)
@@ -476,6 +476,7 @@ namespace TVMediaHub.Tizen.Views
                     ContextPopupItemSelectedHandler?.Invoke(VideoInfo, VideoContextPopupItem.Delete);
                     break;
             }
+
             ctxPopup.Dismiss();
         }
     }
index 5ad92444ddd4ee6bd77fa49d9c53961d428215a2..8ef7fe91051b8ba97837593639881556e083afc6 100755 (executable)
@@ -270,6 +270,7 @@ namespace TVMediaHub.Tizen.Views
                         DbgPort.D(ex.Message);
                         return;
                     }
+
                     PrepareAsync();
                 }
             }
@@ -499,7 +500,7 @@ namespace TVMediaHub.Tizen.Views
         /// <summary>
         /// Sets the play time on the control area
         /// </summary>
-        /// <param name="time"></param>
+        /// <param name="time">A current playing time</param>
         private void SetPlayTime(int time)
         {
             int second = (time / 1000) % 60;
@@ -558,6 +559,7 @@ namespace TVMediaHub.Tizen.Views
         /// <summary>e
         /// A method for hiding control area when timer is over
         /// </summary>
+        /// <param name="state">The status to be set</param>
         private void HideControlAreaHandler(object state)
         {
             SetControlAreaState(ControlAreaState.HIDE);
index 868e5e63be555be2607f47a471e66dc84d9b9f64..86b10ddb2182aaa38c17848cc0eebaa0a89c896c 100755 (executable)
@@ -25,12 +25,10 @@ using TVMediaHub.Tizen.Utils;
 using TVMediaHub.Tizen.ViewModels;
 using Xamarin.Forms;
 using Xamarin.Forms.PlatformConfiguration.TizenSpecific;
-using Tizen.Content.MediaContent;
-using static TVMediaHub.Tizen.Views.VideoItem;
-using Tizen.Xamarin.Forms.Extension;
 
 namespace TVMediaHub.Tizen.Views
 {
+    using static TVMediaHub.Tizen.Views.VideoItem;
     /// <summary>
     /// A custom ContentPage for displaying the video tab
     /// </summary>
@@ -663,6 +661,7 @@ namespace TVMediaHub.Tizen.Views
             App.MainWindow.KeyUp -= MenuKeyListener;
             App.MainWindow.KeyUngrab(ElmSharp.EvasKeyEventArgs.PlatformMenuButtonName);
         }
+
         private void MenuKeyListener(object sender, ElmSharp.EvasKeyEventArgs e)
         {
             if (e.KeyName.Equals(ElmSharp.EvasKeyEventArgs.PlatformMenuButtonName))
@@ -675,7 +674,7 @@ namespace TVMediaHub.Tizen.Views
         {
             if (VideoTabList.Children.Count > 0)
             {
-                foreach(VideoGroup group in VideoTabList.Children)
+                foreach (VideoGroup group in VideoTabList.Children)
                 {
                     if (group.NotifyMenuKeyPressedToFocusedItem())
                     {
@@ -705,6 +704,7 @@ namespace TVMediaHub.Tizen.Views
                     {
                         DeleteContentCommand?.Execute(item);
                     }
+
                     break;
             }
         }