Exemple #1
0
        private void Favorite_Handler(bool isFavorite)
        {
            Recipe recipe = (FavoriteListView.SelectedItem as Recipe);

            recipe.Favorite = isFavorite;

            RecipeDAO.UpdateListRecipes(recipe);
            showFavoriteList();
        }
Exemple #2
0
        private void Favorite_Handler(bool isFavorite)
        {
            Recipe recipe = (DataListview.SelectedItem as Recipe);

            if (recipe.Favorite != isFavorite)
            {
                recipe.Favorite = isFavorite;
                RecipeDAO.UpdateListRecipes(recipe);
            }
            //MessageBox.Show(recipe.Name, (isFavorite) ? "true" : "false");
        }