Added documentation.
authorAndrzej Krawczyk <a.krawczyk@samsung.com>
Wed, 28 Jul 2021 11:19:58 +0000 (13:19 +0200)
committerPiotr Czaja <p.czaja@samsung.com>
Tue, 14 Sep 2021 11:01:34 +0000 (13:01 +0200)
Fitness/ViewModels/ExercisingViewModel.cs
Fitness/ViewModels/LoadingViewModel.cs
Fitness/Views/ExercisingView.xaml.cs
Fitness/Views/LoadingView.cs

index 47e24b8b57f30926828eabe45d5fcc90820a120f..c8f49529b21e1b51175ba9e4fd242bac19bbf7b0 100644 (file)
@@ -48,8 +48,14 @@ namespace Fitness.ViewModels
             SummaryBackCommand = new Command(ExecuteCloseSummary);
         }
 
+        /// <summary>
+        /// Gets a <see cref="ICommand"/> of SummaryView back button.
+        /// </summary>
         public ICommand SummaryBackCommand { get; private set; }
 
+        /// <summary>
+        /// Gets a <see cref="ICommand"/> of SummaryView ok button.
+        /// </summary>
         public ICommand SummaryOkCommand
         {
             get => summaryOkCommand;
@@ -63,6 +69,9 @@ namespace Fitness.ViewModels
             }
         }
 
+        /// <summary>
+        /// Gets or sets a value indicating whether the loading view is visible and counting.
+        /// </summary>
         public bool IsLoading
         {
             get => isLoading;
@@ -76,6 +85,9 @@ namespace Fitness.ViewModels
             }
         }
 
+        /// <summary>
+        /// Gets a title text of summary pop-up.
+        /// </summary>
         public string SummaryTitle
         {
             get => summaryTitle;
@@ -116,7 +128,6 @@ namespace Fitness.ViewModels
         public int TotalCount { get; private set; } = 27;
 
         /// <summary>
-        /// Repetitions made in current Workout
         /// Gets the property specifying the correctness of the exercise - values ranging from 0 to 100.
         /// </summary>
         public int Score
@@ -175,7 +186,7 @@ namespace Fitness.ViewModels
         public TimeSpan TimeLeft { get; private set; } = TimeSpan.FromSeconds(27);
 
         /// <summary>
-        /// Gets the current workout state.
+        /// Gets or sets the current workout state.
         /// </summary>
         public WorkoutState State
         {
@@ -205,6 +216,9 @@ namespace Fitness.ViewModels
         /// </summary>
         public string PreviewVideoUrl { get; private set; }
 
+        /// <summary>
+        /// Gets a value indicating whether the summary pop-up is visible.
+        /// </summary>
         public bool IsSummaryVisible
         {
             get => isSummaryVisible;
@@ -325,7 +339,7 @@ namespace Fitness.ViewModels
 
         private void ConfirmTryAgain()
         {
-            SummaryOkCommand = new Command(() => { ExecuteChangeWorkout(0); });
+            SummaryOkCommand = new Command(() => { ExecuteChangeWorkout(); });
             SummaryTitle = GetSummaryTitle(SummaryType.TryAgain);
             IsSummaryVisible = true;
         }
index 23e17f03d11b26e76e2a879187c486cd5abf78aa..a22967a78b2b0ddbea7c783211990b5743100fc2 100644 (file)
@@ -62,6 +62,9 @@ namespace Fitness.ViewModels
             }
         }
 
+        /// <summary>
+        /// Starts counting down.
+        /// </summary>
         public void StartCounting()
         {
             int count = 0;
index 2424caf6c1906d50297209e45850cc71cc528e77..b0bf819de4282da213208f7b673898eb694993db 100644 (file)
@@ -12,6 +12,9 @@ namespace Fitness.Views
 {
     public partial class ExercisingView : Fitness.Controls.Page
     {
+        /// <summary>
+        /// Is workout playing bindable property.
+        /// </summary>
         public static readonly BindableProperty IsPlayingProperty = BindableProperty.Create(
             "IsPlaying",
             typeof(bool),
@@ -19,6 +22,9 @@ namespace Fitness.Views
             true,
             propertyChanged: OnIsPlayingChanged);
 
+        /// <summary>
+        /// Is workout loading bindable property.
+        /// </summary>
         public static readonly BindableProperty IsLoadingProperty = BindableProperty.Create(
             "IsLoading",
             typeof(bool),
index 21b6d7932fca6c5b820aa23122d84085ce321190..ffeeffbc8b27069ef565e44848d3828470a60863 100644 (file)
@@ -21,6 +21,9 @@ namespace Fitness.Views
 
         public event EventHandler Loaded;
 
+        /// <summary>
+        /// Shows the loading view and starts counting down.
+        /// </summary>
         public void StartLoading()
         {
             if (BindingContext is LoadingViewModel viewModel)