Exemple #1
0
    void HandleAddPressed()
    {
        ExerciseListItem exerciseListItem = Instantiate(exerciseListItemPrefab);

        exerciseListItem.transform.SetParent(grid.transform);
        exerciseListItem.transform.localScale = Vector3.one;
        addExerciseButton.transform.SetAsLastSibling();
    }
Exemple #2
0
        private void AddExercise()
        {
            var exercise = new ExerciseListItem
            {
                Title              = $"Added Exercise Item - {DateTime.Now}",
                DifficultyRating   = 3,
                PracticalityRating = 4,
                Scribed            = false,
                SuggestedDuration  = 120,
                Notes              = $"Here is a sample note - {DateTime.Now}"
            };

            ExerciseList.Add(exercise);
            SelectedExercise = exercise;
        }