diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..f5945cf
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,234 @@
+.DS_Store
+node_modules
+.tmp
+npm-debug.log
+
+
+## Ignore Visual Studio temporary files, build results, and
+## files generated by popular Visual Studio add-ons.
+
+# User-specific files
+*.suo
+*.user
+*.userosscache
+*.sln.docstates
+
+# User-specific files (MonoDevelop/Xamarin Studio)
+*.userprefs
+
+# Build results
+[Dd]ebug/
+[Dd]ebugPublic/
+[Rr]elease/
+[Rr]eleases/
+x64/
+x86/
+
+# We have custom build targets in here so include it.
+# build/
+bld/
+[Bb]in/
+[Oo]bj/
+packages/
+
+# Visual Studo 2015 cache/options directory
+.vs/
+
+# MSTest test Results
+[Tt]est[Rr]esult*/
+[Bb]uild[Ll]og.*
+
+# NUNIT
+*.VisualState.xml
+TestResult.xml
+
+# Build Results of an ATL Project
+[Dd]ebugPS/
+[Rr]eleasePS/
+dlldata.c
+
+*_i.c
+*_p.c
+*_i.h
+*.ilk
+*.meta
+*.obj
+*.pch
+*.pdb
+*.pgc
+*.pgd
+*.rsp
+*.sbr
+*.tlb
+*.tli
+*.tlh
+*.tmp
+*.tmp_proj
+*.log
+*.vspscc
+*.vssscc
+.builds
+*.pidb
+*.svclog
+*.scc
+
+# Chutzpah Test files
+_Chutzpah*
+
+# Visual C++ cache files
+ipch/
+*.aps
+*.ncb
+*.opensdf
+*.sdf
+*.cachefile
+
+# Visual Studio profiler
+*.psess
+*.vsp
+*.vspx
+
+# TFS 2012 Local Workspace
+$tf/
+
+# Guidance Automation Toolkit
+*.gpState
+
+# ReSharper is a .NET coding add-in
+_ReSharper*/
+*.[Rr]e[Ss]harper
+*.DotSettings.user
+
+# JustCode is a .NET coding addin-in
+.JustCode
+
+# TeamCity is a build add-in
+_TeamCity*
+
+# DotCover is a Code Coverage Tool
+*.dotCover
+
+# NCrunch
+_NCrunch_*
+.*crunch*.local.xml
+
+# MightyMoose
+*.mm.*
+AutoTest.Net/
+
+# Web workbench (sass)
+.sass-cache/
+
+# Installshield output folder
+[Ee]xpress/
+
+# DocProject is a documentation generator add-in
+DocProject/buildhelp/
+DocProject/Help/*.HxT
+DocProject/Help/*.HxC
+DocProject/Help/*.hhc
+DocProject/Help/*.hhk
+DocProject/Help/*.hhp
+DocProject/Help/Html2
+DocProject/Help/html
+
+# Click-Once directory
+publish/
+
+# Publish Web Output
+*.[Pp]ublish.xml
+*.azurePubxml
+# TODO: Comment the next line if you want to checkin your web deploy settings
+# but database connection strings (with potential passwords) will be unencrypted
+*.pubxml
+*.publishproj
+
+# NuGet Packages
+*.nupkg
+*.nuget.targets
+# The packages folder can be ignored because of Package Restore
+**/packages/*.
+# except build/, which is used as an MSBuild target.
+!**/packages/build/
+# Uncomment if necessary however generally it will be regenerated when needed
+#!**/packages/repositories.config
+
+# Windows Azure Build Output
+csx/
+*.build.csdef
+
+# Windows Store app package directory
+AppPackages/
+
+# Others
+*.[Cc]ache
+ClientBin/
+[Ss]tyle[Cc]op.*
+~$*
+*~
+*.dbmdl
+*.dbproj.schemaview
+# *.pfx
+*.publishsettings
+node_modules/
+bower_components/
+
+# RIA/Silverlight projects
+Generated_Code/
+
+# Backup & report files from converting an old project file
+# to a newer Visual Studio version. Backup files are not needed,
+# because we have git ;-)
+_UpgradeReport_Files/
+Backup*/
+UpgradeLog*.XML
+UpgradeLog*.htm
+
+# SQL Server files
+*.mdf
+*.ldf
+
+# Business Intelligence projects
+*.rdl.data
+*.bim.layout
+*.bim_*.settings
+
+# Microsoft Fakes
+FakesAssemblies/
+
+# Node.js Tools for Visual Studio
+.ntvs_analysis.dat
+
+# Visual Studio 6 build log
+*.plg
+
+# Visual Studio 6 workspace options file
+*.opt
+
+project.lock.json
+
+### Windows ###
+# Windows thumbnail cache files
+Thumbs.db
+Thumbs.db:encryptable
+ehthumbs.db
+ehthumbs_vista.db
+
+# Dump file
+*.stackdump
+
+# Folder config file
+[Dd]esktop.ini
+
+# Recycle Bin used on file shares
+$RECYCLE.BIN/
+
+# Windows Installer files
+*.cab
+*.msi
+*.msix
+*.msm
+*.msp
+
+# Windows shortcuts
+*.lnk
\ No newline at end of file
diff --git a/Beispieldateien/Data/Category.cs b/Beispieldateien/Data/Category.cs
new file mode 100644
index 0000000..2d13767
--- /dev/null
+++ b/Beispieldateien/Data/Category.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Category
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Beispieldateien/Data/Dish.cs b/Beispieldateien/Data/Dish.cs
new file mode 100644
index 0000000..ce1d48d
--- /dev/null
+++ b/Beispieldateien/Data/Dish.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Dish
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ public decimal Price { get; set; }
+ public int CategoryId { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Beispieldateien/Data/DummyDataService.cs b/Beispieldateien/Data/DummyDataService.cs
new file mode 100644
index 0000000..3e87a00
--- /dev/null
+++ b/Beispieldateien/Data/DummyDataService.cs
@@ -0,0 +1,219 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+public class DummyDataService : IDataService
+{
+ private readonly List _categories;
+ private readonly List _dishes;
+
+ public DummyDataService()
+ {
+ _categories
+ = new List
+ {
+ new Category { Id = 1, Name = "Ensaladas", Description = "Salate" },
+ new Category { Id = 2, Name = "Cremas y sopas", Description = "Suppen" },
+ new Category { Id = 3, Name = "Tapas", Description = "Kleine Portionen" },
+ new Category { Id = 4, Name = "Platos principales", Description = "Hauptgerichte" },
+ new Category { Id = 5, Name = "Postres", Description = "Desserts" },
+ new Category { Id = 6, Name = "Bebidas", Description = "Getränke" }
+ };
+
+ _dishes = new List
+ {
+ new Dish
+ {
+ Id = 1,
+ Name = "Ensalada de Casa",
+ Description = "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ Price = 3.49m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 2,
+ Name = "Ensalada furia",
+ Description = "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ Price = 3.99m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 3,
+ Name = "Sopa de Tomate",
+ Description = "Tomatensuppe",
+ Price = 3.29m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 4,
+ Name = "Crema de verduras",
+ Description = "Gemüsecremesuppe",
+ Price = 4.39m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 5,
+ Name = "Tortilla de patatas",
+ Description = "Spanisches Omlett aus Eiern und Kartoffeln",
+ Price = 4.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 6,
+ Name = "Patatas bravas",
+ Description = "Gebratene Kartoffelstücke in pikanter Sauce",
+ Price = 3.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 7,
+ Name = "Pimientos al grill",
+ Description = "Gegrillte Paprika",
+ Price = 2.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 8,
+ Name = "Pan con alioli",
+ Description = "Ailoli mit Brot",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 9,
+ Name = "Pan con tomate y ajo",
+ Description = "Brot mit Tomate und Knoblauch",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 10,
+ Name = "Tortilla Chips",
+ Description = "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ Price = 1.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 11,
+ Name = "Chilli sin carne",
+ Description = "Vegetarisches Chilli, serviert mit Reis",
+ Price = 5.39m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 12,
+ Name = "Enchiladas de verduras",
+ Description = "Überbackene Maistortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 13,
+ Name = "Burritos de verduras",
+ Description = "Weizentortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 14,
+ Name = "Arroz con verduras",
+ Description = "Reis-/Gemüsepfanne",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 15,
+ Name = "Empanadas de espinacas y maíz",
+ Description = "Teigtaschen gefüllt mit Spinat und Mais",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 16,
+ Name = "Crema Catalana",
+ Description = "Katalanische Creme",
+ Price = 2.49m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 17,
+ Name = "Ensalada de frutas",
+ Description = "Obstsalat mit frischen Früchten",
+ Price = 2.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 18,
+ Name = "Churros",
+ Description = "Spritzgebäck mit Zucker",
+ Price = 1.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 19,
+ Name = "Agua mineral",
+ Description = "Mineralwasser",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 20,
+ Name = "Zumo de manzana",
+ Description = "Apfelsaft",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 21,
+ Name = "Limonada",
+ Description = "Zitronenlimonade",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 22,
+ Name = "Café",
+ Description = "Kaffee",
+ Price = 1.59m,
+ CategoryId = 6
+ }
+ };
+ }
+
+ public Task> GetCategoriesAsync()
+ {
+ return Task.FromResult(_categories);
+ }
+
+ public Task> GetDishesAsync(int? categoryId = null)
+ {
+ return categoryId.HasValue
+ ? Task.FromResult(_dishes.Where(d => d.CategoryId == categoryId).ToList())
+ : Task.FromResult(_dishes);
+ }
+
+ public Task GetDishAsync(int id)
+ {
+ return Task.FromResult(_dishes.SingleOrDefault(d => d.Id == id));
+ }
+}
\ No newline at end of file
diff --git a/Beispieldateien/Data/IDataService.cs b/Beispieldateien/Data/IDataService.cs
new file mode 100644
index 0000000..ea070e4
--- /dev/null
+++ b/Beispieldateien/Data/IDataService.cs
@@ -0,0 +1,12 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+
+public interface IDataService
+{
+ Task> GetCategoriesAsync();
+ Task> GetDishesAsync(int? categoryId = null);
+ Task GetDishAsync(int id);
+}
\ No newline at end of file
diff --git a/Beispieldateien/Data/JsonDataService.cs b/Beispieldateien/Data/JsonDataService.cs
new file mode 100644
index 0000000..98338a2
--- /dev/null
+++ b/Beispieldateien/Data/JsonDataService.cs
@@ -0,0 +1,66 @@
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Reflection;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+using Newtonsoft.Json;
+
+namespace ElVegetarianoFurio.Data
+{
+ public class JsonDataService : IDataService
+ {
+ private RestaurantData _data;
+ private async Task GetRestaurantData()
+ {
+ if (_data != null)
+ {
+ return _data;
+ }
+ //var assembly = IntrospectionExtensions.GetTypeInfo(GetType()).Assembly;
+ var assembly = GetType().Assembly;
+
+ var stream = assembly.GetManifestResourceStream("ElVegetarianoFurio.Data.db.json");
+
+ string json;
+
+ using (var reader = new StreamReader(stream))
+ {
+ json = await reader.ReadToEndAsync();
+ }
+
+ _data = JsonConvert.DeserializeObject(json);
+ return _data;
+ }
+
+ public async Task> GetCategoriesAsync()
+ {
+ var data = await GetRestaurantData();
+ return data.Categories;
+ }
+
+ public async Task> GetDishesAsync(int? categoryId = null)
+ {
+ var dishes = (await GetRestaurantData()).Dishes;
+
+ if (categoryId.HasValue)
+ {
+ dishes = dishes.Where(d => d.CategoryId == categoryId).ToList();
+ }
+
+ return dishes;
+ }
+
+ public async Task GetDishAsync(int id)
+ {
+ var dishes = (await GetRestaurantData()).Dishes;
+ return dishes.SingleOrDefault(d => d.Id == id);
+ }
+
+ private class RestaurantData
+ {
+ public List Categories { get; set; }
+ public List Dishes { get; set; }
+ }
+ }
+}
\ No newline at end of file
diff --git a/Beispieldateien/Data/db.json b/Beispieldateien/Data/db.json
new file mode 100644
index 0000000..9d44e4c
--- /dev/null
+++ b/Beispieldateien/Data/db.json
@@ -0,0 +1,190 @@
+{
+ "categories": [
+ {
+ "id": 1,
+ "name": "Ensaladas",
+ "description": "Salate"
+ },
+ {
+ "id": 2,
+ "name": "Cremas y sopas",
+ "description": "Suppen"
+ },
+ {
+ "id": 3,
+ "name": "Tapas",
+ "description": "Kleine Portionen"
+ },
+ {
+ "id": 4,
+ "name": "Platos principales",
+ "description": "Hauptgerichte"
+ },
+ {
+ "id": 5,
+ "name": "Postres",
+ "description": "Desserts"
+ },
+ {
+ "id": 6,
+ "name": "Bebidas",
+ "description": "Getränke"
+ }
+ ],
+ "dishes": [
+ {
+ "id": 1,
+ "name": "Ensalada de Casa",
+ "description": "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ "price": 3.49,
+ "categoryId": 1
+ },
+ {
+ "id": 2,
+ "name": "Ensalada furia",
+ "description": "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ "price": 3.99,
+ "categoryId": 1
+ },
+ {
+ "id": 3,
+ "name": "Sopa de Tomate",
+ "description": "Tomatensuppe",
+ "price": 3.29,
+ "categoryId": 2
+ },
+ {
+ "id": 4,
+ "name": "Crema de verduras",
+ "description": "Gemüsecremesuppe",
+ "price": 4.39,
+ "categoryId": 2
+ },
+ {
+ "id": 5,
+ "name": "Tortilla de patatas",
+ "description": "Spanisches Omlett aus Eiern und Kartoffeln",
+ "price": 4.99,
+ "categoryId": 3
+ },
+ {
+ "id": 6,
+ "name": "Patatas bravas",
+ "description": "Gebratene Kartoffelstücke in pikanter Sauce",
+ "price": 3.99,
+ "categoryId": 3
+ },
+ {
+ "id": 7,
+ "name": "Pimientos al grill",
+ "description": "Gegrillte Paprika",
+ "price": 2.99,
+ "categoryId": 3
+ },
+ {
+ "id": 8,
+ "name": "Pan con alioli",
+ "description": "Ailoli mit Brot",
+ "price": 2.29,
+ "categoryId": 3
+ },
+ {
+ "id": 9,
+ "name": "Pan con tomate y ajo",
+ "description": "Brot mit Tomate und Knoblauch",
+ "price": 2.29,
+ "categoryId": 3
+ },
+ {
+ "id": 10,
+ "name": "Tortilla Chips",
+ "description": "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ "price": 1.29,
+ "categoryId": 3
+ },
+ {
+ "id": 11,
+ "name": "Chilli sin carne",
+ "description": "Vegetarisches Chilli, serviert mit Reis",
+ "price": 5.39,
+ "categoryId": 4
+ },
+ {
+ "id": 12,
+ "name": "Enchiladas de verduras",
+ "description": "Überbackene Maistortillas gefüllt mit Gemüse",
+ "price": 4.99,
+ "categoryId": 4
+ },
+ {
+ "id": 13,
+ "name": "Burritos de verduras",
+ "description": "Weizentortillas gefüllt mit Gemüse",
+ "price": 4.99,
+ "categoryId": 4
+ },
+ {
+ "id": 14,
+ "name": "Arroz con verduras",
+ "description": "Reis-/Gemüsepfanne",
+ "price": 4.49,
+ "categoryId": 4
+ },
+ {
+ "id": 15,
+ "name": "Empanadas de espinacas y maíz",
+ "description": "Teigtaschen gefüllt mit Spinat und Mais",
+ "price": 4.49,
+ "categoryId": 4
+ },
+ {
+ "id": 16,
+ "name": "Crema Catalana",
+ "description": "Katalanische Creme",
+ "price": 2.49,
+ "categoryId": 5
+ },
+ {
+ "id": 17,
+ "name": "Ensalada de frutas",
+ "description": "Obstsalat mit frischen Früchten",
+ "price": 2.99,
+ "categoryId": 5
+ },
+ {
+ "id": 18,
+ "name": "Churros",
+ "description": "Spritzgebäck mit Zucker",
+ "price": 1.99,
+ "categoryId": 5
+ },
+ {
+ "id": 19,
+ "name": "Agua mineral",
+ "description": "Mineralwasser",
+ "price": 1.59,
+ "categoryId": 6
+ },
+ {
+ "id": 20,
+ "name": "Zumo de manzana",
+ "description": "Apfelsaft",
+ "price": 1.59,
+ "categoryId": 6
+ },
+ {
+ "id": 21,
+ "name": "Limonada",
+ "description": "Zitronenlimonade",
+ "price": 1.59,
+ "categoryId": 6
+ },
+ {
+ "id": 22,
+ "name": "Café",
+ "description": "Kaffee",
+ "price": 1.59,
+ "categoryId": 6
+ }
+ ]
+}
\ No newline at end of file
diff --git a/Beispieldateien/Fonts/FaSolid.cs b/Beispieldateien/Fonts/FaSolid.cs
new file mode 100644
index 0000000..0abcd8d
--- /dev/null
+++ b/Beispieldateien/Fonts/FaSolid.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Fonts
+{
+ // Generated by IconFont2Code: https://andreinitescu.github.io/IconFont2Code
+ // If you change the class to 'public' in order to use it outside its assembly
+ // you should also change the fields from 'const' to 'public static readonly'
+ static class FaSolid
+ {
+ public const string Home = "\uf015";
+ public const string Utensils = "\uf2e7";
+ public const string Carrot = "\uf787";
+ public const string UtensilSpoon = "\uf2e5";
+ public const string PepperHot = "\uf816";
+ public const string IceCream = "\uf810";
+ public const string GlassCheers = "\uf79f";
+ public const string UserCircle = "\uf2bd";
+ public const string MapMarkedAlt = "\uf5a0";
+ public const string Phone = "\uf095";
+ }
+}
\ No newline at end of file
diff --git a/Beispieldateien/Fonts/Font Awesome 5 Free-Solid-900.otf b/Beispieldateien/Fonts/Font Awesome 5 Free-Solid-900.otf
new file mode 100644
index 0000000..8fb28d5
Binary files /dev/null and b/Beispieldateien/Fonts/Font Awesome 5 Free-Solid-900.otf differ
diff --git a/Beispieldateien/Fonts/License Font Awesome.txt b/Beispieldateien/Fonts/License Font Awesome.txt
new file mode 100644
index 0000000..f31bef9
--- /dev/null
+++ b/Beispieldateien/Fonts/License Font Awesome.txt
@@ -0,0 +1,34 @@
+Font Awesome Free License
+-------------------------
+
+Font Awesome Free is free, open source, and GPL friendly. You can use it for
+commercial projects, open source projects, or really almost whatever you want.
+Full Font Awesome Free license: https://fontawesome.com/license/free.
+
+# Icons: CC BY 4.0 License (https://creativecommons.org/licenses/by/4.0/)
+In the Font Awesome Free download, the CC BY 4.0 license applies to all icons
+packaged as SVG and JS file types.
+
+# Fonts: SIL OFL 1.1 License (https://scripts.sil.org/OFL)
+In the Font Awesome Free download, the SIL OFL license applies to all icons
+packaged as web and desktop font files.
+
+# Code: MIT License (https://opensource.org/licenses/MIT)
+In the Font Awesome Free download, the MIT license applies to all non-font and
+non-icon files.
+
+# Attribution
+Attribution is required by MIT, SIL OFL, and CC BY licenses. Downloaded Font
+Awesome Free files already contain embedded comments with sufficient
+attribution, so you shouldn't need to do anything additional when using these
+files normally.
+
+We've kept attribution comments terse, so we ask that you do not actively work
+to remove them from files, especially code. They're a great way for folks to
+learn about Font Awesome.
+
+# Brand Icons
+All brand icons are trademarks of their respective owners. The use of these
+trademarks does not indicate endorsement of the trademark holder by Font
+Awesome, nor vice versa. **Please do not use brand logos for any purpose except
+to represent the company, product, or service to which they refer.**
diff --git a/Beispieldateien/Fonts/License Shadows.txt b/Beispieldateien/Fonts/License Shadows.txt
new file mode 100644
index 0000000..06117d9
--- /dev/null
+++ b/Beispieldateien/Fonts/License Shadows.txt
@@ -0,0 +1,93 @@
+Copyright (c) 2010, Kimberly Geswein (kimberlygeswein.com)
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at:
+http://scripts.sil.org/OFL
+
+
+-----------------------------------------------------------
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+-----------------------------------------------------------
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide
+development of collaborative font projects, to support the font creation
+efforts of academic and linguistic communities, and to provide a free and
+open framework in which fonts may be shared and improved in partnership
+with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and
+redistributed freely as long as they are not sold by themselves. The
+fonts, including any derivative works, can be bundled, embedded,
+redistributed and/or sold with any software provided that any reserved
+names are not used by derivative works. The fonts and derivatives,
+however, cannot be released under any other type of license. The
+requirement for fonts to remain under this license does not apply
+to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright
+Holder(s) under this license and clearly marked as such. This may
+include source files, build scripts and documentation.
+
+"Reserved Font Name" refers to any names specified as such after the
+copyright statement(s).
+
+"Original Version" refers to the collection of Font Software components as
+distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting,
+or substituting -- in part or in whole -- any of the components of the
+Original Version, by changing formats or by porting the Font Software to a
+new environment.
+
+"Author" refers to any designer, engineer, programmer, technical
+writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of the Font Software, to use, study, copy, merge, embed, modify,
+redistribute, and sell modified and unmodified copies of the Font
+Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components,
+in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled,
+redistributed and/or sold with any software, provided that each copy
+contains the above copyright notice and this license. These can be
+included either as stand-alone text files, human-readable headers or
+in the appropriate machine-readable metadata fields within text or
+binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font
+Name(s) unless explicit written permission is granted by the corresponding
+Copyright Holder. This restriction only applies to the primary font name as
+presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
+Software shall not be used to promote, endorse or advertise any
+Modified Version, except to acknowledge the contribution(s) of the
+Copyright Holder(s) and the Author(s) or with their explicit written
+permission.
+
+5) The Font Software, modified or unmodified, in part or in whole,
+must be distributed entirely under this license, and must not be
+distributed under any other license. The requirement for fonts to
+remain under this license does not apply to any document created
+using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are
+not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
+OTHER DEALINGS IN THE FONT SOFTWARE.
diff --git a/Beispieldateien/Fonts/License Sofia.txt b/Beispieldateien/Fonts/License Sofia.txt
new file mode 100644
index 0000000..4270e3e
--- /dev/null
+++ b/Beispieldateien/Fonts/License Sofia.txt
@@ -0,0 +1,94 @@
+Copyright (c) 2011 by LatinoType Limitada (luciano@latinotype.com),
+with Reserved Font Names "Sofia"
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at:
+http://scripts.sil.org/OFL
+
+
+-----------------------------------------------------------
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+-----------------------------------------------------------
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide
+development of collaborative font projects, to support the font creation
+efforts of academic and linguistic communities, and to provide a free and
+open framework in which fonts may be shared and improved in partnership
+with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and
+redistributed freely as long as they are not sold by themselves. The
+fonts, including any derivative works, can be bundled, embedded,
+redistributed and/or sold with any software provided that any reserved
+names are not used by derivative works. The fonts and derivatives,
+however, cannot be released under any other type of license. The
+requirement for fonts to remain under this license does not apply
+to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright
+Holder(s) under this license and clearly marked as such. This may
+include source files, build scripts and documentation.
+
+"Reserved Font Name" refers to any names specified as such after the
+copyright statement(s).
+
+"Original Version" refers to the collection of Font Software components as
+distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting,
+or substituting -- in part or in whole -- any of the components of the
+Original Version, by changing formats or by porting the Font Software to a
+new environment.
+
+"Author" refers to any designer, engineer, programmer, technical
+writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of the Font Software, to use, study, copy, merge, embed, modify,
+redistribute, and sell modified and unmodified copies of the Font
+Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components,
+in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled,
+redistributed and/or sold with any software, provided that each copy
+contains the above copyright notice and this license. These can be
+included either as stand-alone text files, human-readable headers or
+in the appropriate machine-readable metadata fields within text or
+binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font
+Name(s) unless explicit written permission is granted by the corresponding
+Copyright Holder. This restriction only applies to the primary font name as
+presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
+Software shall not be used to promote, endorse or advertise any
+Modified Version, except to acknowledge the contribution(s) of the
+Copyright Holder(s) and the Author(s) or with their explicit written
+permission.
+
+5) The Font Software, modified or unmodified, in part or in whole,
+must be distributed entirely under this license, and must not be
+distributed under any other license. The requirement for fonts to
+remain under this license does not apply to any document created
+using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are
+not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
+OTHER DEALINGS IN THE FONT SOFTWARE.
diff --git a/Beispieldateien/Fonts/ShadowsIntoLight-Regular.ttf b/Beispieldateien/Fonts/ShadowsIntoLight-Regular.ttf
new file mode 100644
index 0000000..b7bc796
Binary files /dev/null and b/Beispieldateien/Fonts/ShadowsIntoLight-Regular.ttf differ
diff --git a/Beispieldateien/Fonts/Sofia-Regular.ttf b/Beispieldateien/Fonts/Sofia-Regular.ttf
new file mode 100644
index 0000000..aaee088
Binary files /dev/null and b/Beispieldateien/Fonts/Sofia-Regular.ttf differ
diff --git a/Beispieldateien/Images/Categories/category1.jpg b/Beispieldateien/Images/Categories/category1.jpg
new file mode 100644
index 0000000..5287632
Binary files /dev/null and b/Beispieldateien/Images/Categories/category1.jpg differ
diff --git a/Beispieldateien/Images/Categories/category2.jpg b/Beispieldateien/Images/Categories/category2.jpg
new file mode 100644
index 0000000..d2e1756
Binary files /dev/null and b/Beispieldateien/Images/Categories/category2.jpg differ
diff --git a/Beispieldateien/Images/Categories/category3.jpg b/Beispieldateien/Images/Categories/category3.jpg
new file mode 100644
index 0000000..ad87a41
Binary files /dev/null and b/Beispieldateien/Images/Categories/category3.jpg differ
diff --git a/Beispieldateien/Images/Categories/category4.jpg b/Beispieldateien/Images/Categories/category4.jpg
new file mode 100644
index 0000000..4daa8f9
Binary files /dev/null and b/Beispieldateien/Images/Categories/category4.jpg differ
diff --git a/Beispieldateien/Images/Categories/category5.jpg b/Beispieldateien/Images/Categories/category5.jpg
new file mode 100644
index 0000000..cc079b2
Binary files /dev/null and b/Beispieldateien/Images/Categories/category5.jpg differ
diff --git a/Beispieldateien/Images/Categories/category6.jpg b/Beispieldateien/Images/Categories/category6.jpg
new file mode 100644
index 0000000..c6c5c3b
Binary files /dev/null and b/Beispieldateien/Images/Categories/category6.jpg differ
diff --git a/Beispieldateien/Images/Categories/credits.txt b/Beispieldateien/Images/Categories/credits.txt
new file mode 100644
index 0000000..11003bc
--- /dev/null
+++ b/Beispieldateien/Images/Categories/credits.txt
@@ -0,0 +1,23 @@
+category1.jpg
+https://unsplash.com/photos/IGfIGP5ONV0
+Unsplash / Anna Pelzer
+
+category2.jpg
+https://unsplash.com/photos/OMcrCX6wDpU
+Unsplash / Jade Aucamp
+
+category3.jpg
+https://pixabay.com/de/photos/creme-k%C3%A4se-tomate-sousse-chips-1503526/
+Pixybay / hamomdomingues
+
+category4.jpg
+https://www.pexels.com/photo/blur-bowl-close-up-cook-461326/
+Pexels / Pixabay
+
+category5.jpg
+https://pixabay.com/de/photos/eisbecher-speiseeis-eiscreme-2194070/
+Pixybay / silviarita
+
+category6.jpg
+https://mavl.io/photo/7331/summer-drink
+Mavl / picjumbo.com
\ No newline at end of file
diff --git a/Beispieldateien/Images/Categories/license.md b/Beispieldateien/Images/Categories/license.md
new file mode 100644
index 0000000..1831ed6
--- /dev/null
+++ b/Beispieldateien/Images/Categories/license.md
@@ -0,0 +1,45 @@
+All pictures are taken from the following sources:
+
+- Mavl
+- Pexels
+- Pixabay
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Mavl
+https://mavl.io/license
+Creative Commons Zero enables artists, photographers, authors, scientists, educators, and other creators and owners of copyright- or database-protected content to waive those interests in their works and thereby place them as completely as possible in the public domain, so that others may freely build upon, enhance and reuse the works for any purposes without restriction under copyright or database law.
+
+In contrast to CC’s licenses that allow copyright holders to choose from a range of permissions while retaining their copyright, CC0 empowers yet another choice altogether – the choice to opt out of copyright and database protection, and the exclusive rights automatically granted to creators – the “no rights reserved” alternative to our licenses.
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+Bilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Beispieldateien/Images/Dishes/credits.txt b/Beispieldateien/Images/Dishes/credits.txt
new file mode 100644
index 0000000..68521e7
--- /dev/null
+++ b/Beispieldateien/Images/Dishes/credits.txt
@@ -0,0 +1,87 @@
+dish1.jpg
+https://unsplash.com/photos/MlPD-AzZYMg
+Unsplash / Louis Hansel
+
+dish2.jpg
+https://unsplash.com/photos/AiHJiRCwB3w
+Unsplash / Yoav Aziz
+
+dish3.jpg
+https://www.pexels.com/photo/appetizer-bowl-bread-breakfast-539451/
+Pexels / Foodie Factor
+
+dish4.jpg
+https://pixabay.com/de/photos/erbsensuppe-suppe-vorspeise-2786133/
+Pixabay / Ritae
+
+dish5.jpg
+https://pxhere.com/en/photo/758610
+pxhere
+
+dish6.jpg
+https://unsplash.com/photos/vzIgmhbEN9w
+Unsplash / Nacho Carretero Molero
+
+dish7.jpg
+https://pxhere.com/de/photo/459409
+pxhere
+
+dish8.jpg
+https://pxhere.com/es/photo/607309
+pxhere
+
+dish9.jpg
+https://pxhere.com/es/photo/529102
+pxhere
+
+dish10.jpg
+https://www.rawpixel.com/image/448047/free-photo-image-dip-mexican-cuisine-appetite
+rawpixel / Jakub Kapusnak
+
+dish11.jpg
+https://pixabay.com/de/photos/tjena-k%C3%BCche-chili-con-carne-reis-3175645/
+pixabay / TJENA
+
+dish12.jpg
+https://unsplash.com/photos/xsfX3AqLDKo
+Unsplash / Alexandra Golovac
+
+dish13.jpg
+https://pixabay.com/de/photos/burrito-tortilla-lebensmittel-4126116/
+pixabay / nevena1313
+
+dish14.jpg
+https://pixnio.com/food-and-drink/rice-food-dinner-lunch-dish-meal-vegetable-meat-delicious
+pixnio
+
+dish15.jpg
+https://pixabay.com/de/photos/empanadas-empanaditas-partei-macht-3410288/
+pixybay / Emersontc
+
+dish16.jpg
+https://pxhere.com/en/photo/863645
+pxhere
+
+
+dish17.jpg
+https://pixnio.com/flora-plants/fruits/fruit-salad-diet-food-nutrition-delicious-kiwi-sweet
+pixnio
+
+dish18.jpg
+https://pixabay.com/de/photos/churros-backen-cookies-dessert-2188871/
+pixabay / Daria-Yakovleva
+
+dish19.jpg
+https://pxhere.com/en/photo/1274085
+
+dish20.jpg
+https://pxhere.com/en/photo/1582781
+pxhere / rawpixel.com
+
+dish21.jpg
+https://unsplash.com/photos/p5EiqkBYIEE
+Unsplash / Francesca Hotchin
+
+dish22.jpg
+https://pxhere.com/en/photo/655302
+pxhere
\ No newline at end of file
diff --git a/Beispieldateien/Images/Dishes/dish1.jpg b/Beispieldateien/Images/Dishes/dish1.jpg
new file mode 100644
index 0000000..b4a8e6b
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish1.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish10.jpg b/Beispieldateien/Images/Dishes/dish10.jpg
new file mode 100644
index 0000000..af6ca2f
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish10.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish11.jpg b/Beispieldateien/Images/Dishes/dish11.jpg
new file mode 100644
index 0000000..be404cc
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish11.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish12.jpg b/Beispieldateien/Images/Dishes/dish12.jpg
new file mode 100644
index 0000000..83e883b
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish12.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish13.jpg b/Beispieldateien/Images/Dishes/dish13.jpg
new file mode 100644
index 0000000..60a51f3
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish13.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish14.jpg b/Beispieldateien/Images/Dishes/dish14.jpg
new file mode 100644
index 0000000..f833169
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish14.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish15.jpg b/Beispieldateien/Images/Dishes/dish15.jpg
new file mode 100644
index 0000000..a2a3be6
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish15.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish16.jpg b/Beispieldateien/Images/Dishes/dish16.jpg
new file mode 100644
index 0000000..b2f1d29
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish16.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish17.jpg b/Beispieldateien/Images/Dishes/dish17.jpg
new file mode 100644
index 0000000..a94addb
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish17.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish18.jpg b/Beispieldateien/Images/Dishes/dish18.jpg
new file mode 100644
index 0000000..e1b4bed
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish18.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish19.jpg b/Beispieldateien/Images/Dishes/dish19.jpg
new file mode 100644
index 0000000..eb5d8ab
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish19.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish2.jpg b/Beispieldateien/Images/Dishes/dish2.jpg
new file mode 100644
index 0000000..0106493
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish2.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish20.jpg b/Beispieldateien/Images/Dishes/dish20.jpg
new file mode 100644
index 0000000..72cbf4f
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish20.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish21.jpg b/Beispieldateien/Images/Dishes/dish21.jpg
new file mode 100644
index 0000000..6cfcda0
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish21.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish22.jpg b/Beispieldateien/Images/Dishes/dish22.jpg
new file mode 100644
index 0000000..5101c63
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish22.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish3.jpg b/Beispieldateien/Images/Dishes/dish3.jpg
new file mode 100644
index 0000000..33ed103
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish3.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish4.jpg b/Beispieldateien/Images/Dishes/dish4.jpg
new file mode 100644
index 0000000..96b9fb1
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish4.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish5.jpg b/Beispieldateien/Images/Dishes/dish5.jpg
new file mode 100644
index 0000000..e1d88a6
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish5.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish6.jpg b/Beispieldateien/Images/Dishes/dish6.jpg
new file mode 100644
index 0000000..fcd2757
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish6.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish7.jpg b/Beispieldateien/Images/Dishes/dish7.jpg
new file mode 100644
index 0000000..9eb85e9
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish7.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish8.jpg b/Beispieldateien/Images/Dishes/dish8.jpg
new file mode 100644
index 0000000..b6b9d0b
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish8.jpg differ
diff --git a/Beispieldateien/Images/Dishes/dish9.jpg b/Beispieldateien/Images/Dishes/dish9.jpg
new file mode 100644
index 0000000..f5f56a0
Binary files /dev/null and b/Beispieldateien/Images/Dishes/dish9.jpg differ
diff --git a/Beispieldateien/Images/Dishes/license.md b/Beispieldateien/Images/Dishes/license.md
new file mode 100644
index 0000000..dfa107d
--- /dev/null
+++ b/Beispieldateien/Images/Dishes/license.md
@@ -0,0 +1,59 @@
+All pictures are taken from the following sources:
+
+- Pexels
+- Pixabay
+- Pixnio
+- Pxhere
+- Rawpixl
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+ilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Pixnio
+https://pixnio.com/de/
+https://pixnio.com/public-domain-definition
+Hochwertige urheberrechts-freundliche Bilder, urheberrechtsfreie Bilder und Bilder ohne Beschränkung für deren Verwendung. Explizit in der Public Domain platzierte Bilder, keine Rechte vorbehalten. Public Domain Bilder können für beliebige Zwecke genutzt werden, nutzen Sie diese frei für persönliche oder kommerzielle Nutzung.
+
+## Pxhere
+https://pxhere.com/de/license
+
+ It's hard to understand complex licenses that is why all photos on PxHere are licensed under the Creative Commons Zero (CC0) license. This means the pictures are completely free to be used for any legal purpose.
+ The pictures are free for personal and even for commercial use.
+ You can modify, copy and distribute the photos.
+ All without asking for permission or setting a link to the source. So, attribution is not required.
+ The only restriction is that identifiable people may not appear in a bad light or in a way that they may find offensive, unless they give their consent.
+ The CC0 license was released by the non-profit organization Creative Commons (CC). Get more information about Creative Commons images and the license on the official license page.
+
+## Rawpixl
+https://www.rawpixel.com/services/image-licenses
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Beispieldateien/Images/category1.jpg b/Beispieldateien/Images/category1.jpg
new file mode 100644
index 0000000..5287632
Binary files /dev/null and b/Beispieldateien/Images/category1.jpg differ
diff --git a/Beispieldateien/Images/category2.jpg b/Beispieldateien/Images/category2.jpg
new file mode 100644
index 0000000..d2e1756
Binary files /dev/null and b/Beispieldateien/Images/category2.jpg differ
diff --git a/Beispieldateien/Images/category3.jpg b/Beispieldateien/Images/category3.jpg
new file mode 100644
index 0000000..ad87a41
Binary files /dev/null and b/Beispieldateien/Images/category3.jpg differ
diff --git a/Beispieldateien/Images/category4.jpg b/Beispieldateien/Images/category4.jpg
new file mode 100644
index 0000000..4daa8f9
Binary files /dev/null and b/Beispieldateien/Images/category4.jpg differ
diff --git a/Beispieldateien/Images/category5.jpg b/Beispieldateien/Images/category5.jpg
new file mode 100644
index 0000000..cc079b2
Binary files /dev/null and b/Beispieldateien/Images/category5.jpg differ
diff --git a/Beispieldateien/Images/category6.jpg b/Beispieldateien/Images/category6.jpg
new file mode 100644
index 0000000..c6c5c3b
Binary files /dev/null and b/Beispieldateien/Images/category6.jpg differ
diff --git a/Beispieldateien/Images/credits.txt b/Beispieldateien/Images/credits.txt
new file mode 100644
index 0000000..572cad7
--- /dev/null
+++ b/Beispieldateien/Images/credits.txt
@@ -0,0 +1,111 @@
+category1.jpg
+https://unsplash.com/photos/IGfIGP5ONV0
+Unsplash / Anna Pelzer
+
+category2.jpg
+https://unsplash.com/photos/OMcrCX6wDpU
+Unsplash / Jade Aucamp
+
+category3.jpg
+https://pixabay.com/de/photos/creme-k%C3%A4se-tomate-sousse-chips-1503526/
+Pixybay / hamomdomingues
+
+category4.jpg
+https://www.pexels.com/photo/blur-bowl-close-up-cook-461326/
+Pexels / Pixabay
+
+category5.jpg
+https://pixabay.com/de/photos/eisbecher-speiseeis-eiscreme-2194070/
+Pixybay / silviarita
+
+category6.jpg
+https://mavl.io/photo/7331/summer-drink
+Mavl / picjumbo.com
+
+dish1.jpg
+https://unsplash.com/photos/MlPD-AzZYMg
+Unsplash / Louis Hansel
+
+dish2.jpg
+https://unsplash.com/photos/AiHJiRCwB3w
+Unsplash / Yoav Aziz
+
+dish3.jpg
+https://www.pexels.com/photo/appetizer-bowl-bread-breakfast-539451/
+Pexels / Foodie Factor
+
+dish4.jpg
+https://pixabay.com/de/photos/erbsensuppe-suppe-vorspeise-2786133/
+Pixabay / Ritae
+
+dish5.jpg
+https://pxhere.com/en/photo/758610
+pxhere
+
+dish6.jpg
+https://unsplash.com/photos/vzIgmhbEN9w
+Unsplash / Nacho Carretero Molero
+
+dish7.jpg
+https://pxhere.com/de/photo/459409
+pxhere
+
+dish8.jpg
+https://pxhere.com/es/photo/607309
+pxhere
+
+dish9.jpg
+https://pxhere.com/es/photo/529102
+pxhere
+
+dish10.jpg
+https://www.rawpixel.com/image/448047/free-photo-image-dip-mexican-cuisine-appetite
+rawpixel / Jakub Kapusnak
+
+dish11.jpg
+https://pixabay.com/de/photos/tjena-k%C3%BCche-chili-con-carne-reis-3175645/
+pixabay / TJENA
+
+dish12.jpg
+https://unsplash.com/photos/xsfX3AqLDKo
+Unsplash / Alexandra Golovac
+
+dish13.jpg
+https://pixabay.com/de/photos/burrito-tortilla-lebensmittel-4126116/
+pixabay / nevena1313
+
+dish14.jpg
+https://pixnio.com/food-and-drink/rice-food-dinner-lunch-dish-meal-vegetable-meat-delicious
+pixnio
+
+dish15.jpg
+https://pixabay.com/de/photos/empanadas-empanaditas-partei-macht-3410288/
+pixybay / Emersontc
+
+dish16.jpg
+https://pxhere.com/en/photo/863645
+pxhere
+
+
+dish17.jpg
+https://pixnio.com/flora-plants/fruits/fruit-salad-diet-food-nutrition-delicious-kiwi-sweet
+pixnio
+
+dish18.jpg
+https://pixabay.com/de/photos/churros-backen-cookies-dessert-2188871/
+pixabay / Daria-Yakovleva
+
+dish19.jpg
+https://pxhere.com/en/photo/1274085
+
+dish20.jpg
+https://pxhere.com/en/photo/1582781
+pxhere / rawpixel.com
+
+dish21.jpg
+https://unsplash.com/photos/p5EiqkBYIEE
+Unsplash / Francesca Hotchin
+
+dish22.jpg
+https://pxhere.com/en/photo/655302
+pxhere
\ No newline at end of file
diff --git a/Beispieldateien/Images/dish1.jpg b/Beispieldateien/Images/dish1.jpg
new file mode 100644
index 0000000..b4a8e6b
Binary files /dev/null and b/Beispieldateien/Images/dish1.jpg differ
diff --git a/Beispieldateien/Images/dish10.jpg b/Beispieldateien/Images/dish10.jpg
new file mode 100644
index 0000000..af6ca2f
Binary files /dev/null and b/Beispieldateien/Images/dish10.jpg differ
diff --git a/Beispieldateien/Images/dish11.jpg b/Beispieldateien/Images/dish11.jpg
new file mode 100644
index 0000000..be404cc
Binary files /dev/null and b/Beispieldateien/Images/dish11.jpg differ
diff --git a/Beispieldateien/Images/dish12.jpg b/Beispieldateien/Images/dish12.jpg
new file mode 100644
index 0000000..83e883b
Binary files /dev/null and b/Beispieldateien/Images/dish12.jpg differ
diff --git a/Beispieldateien/Images/dish13.jpg b/Beispieldateien/Images/dish13.jpg
new file mode 100644
index 0000000..60a51f3
Binary files /dev/null and b/Beispieldateien/Images/dish13.jpg differ
diff --git a/Beispieldateien/Images/dish14.jpg b/Beispieldateien/Images/dish14.jpg
new file mode 100644
index 0000000..f833169
Binary files /dev/null and b/Beispieldateien/Images/dish14.jpg differ
diff --git a/Beispieldateien/Images/dish15.jpg b/Beispieldateien/Images/dish15.jpg
new file mode 100644
index 0000000..a2a3be6
Binary files /dev/null and b/Beispieldateien/Images/dish15.jpg differ
diff --git a/Beispieldateien/Images/dish16.jpg b/Beispieldateien/Images/dish16.jpg
new file mode 100644
index 0000000..b2f1d29
Binary files /dev/null and b/Beispieldateien/Images/dish16.jpg differ
diff --git a/Beispieldateien/Images/dish17.jpg b/Beispieldateien/Images/dish17.jpg
new file mode 100644
index 0000000..a94addb
Binary files /dev/null and b/Beispieldateien/Images/dish17.jpg differ
diff --git a/Beispieldateien/Images/dish18.jpg b/Beispieldateien/Images/dish18.jpg
new file mode 100644
index 0000000..e1b4bed
Binary files /dev/null and b/Beispieldateien/Images/dish18.jpg differ
diff --git a/Beispieldateien/Images/dish19.jpg b/Beispieldateien/Images/dish19.jpg
new file mode 100644
index 0000000..eb5d8ab
Binary files /dev/null and b/Beispieldateien/Images/dish19.jpg differ
diff --git a/Beispieldateien/Images/dish2.jpg b/Beispieldateien/Images/dish2.jpg
new file mode 100644
index 0000000..0106493
Binary files /dev/null and b/Beispieldateien/Images/dish2.jpg differ
diff --git a/Beispieldateien/Images/dish20.jpg b/Beispieldateien/Images/dish20.jpg
new file mode 100644
index 0000000..72cbf4f
Binary files /dev/null and b/Beispieldateien/Images/dish20.jpg differ
diff --git a/Beispieldateien/Images/dish21.jpg b/Beispieldateien/Images/dish21.jpg
new file mode 100644
index 0000000..6cfcda0
Binary files /dev/null and b/Beispieldateien/Images/dish21.jpg differ
diff --git a/Beispieldateien/Images/dish22.jpg b/Beispieldateien/Images/dish22.jpg
new file mode 100644
index 0000000..5101c63
Binary files /dev/null and b/Beispieldateien/Images/dish22.jpg differ
diff --git a/Beispieldateien/Images/dish3.jpg b/Beispieldateien/Images/dish3.jpg
new file mode 100644
index 0000000..33ed103
Binary files /dev/null and b/Beispieldateien/Images/dish3.jpg differ
diff --git a/Beispieldateien/Images/dish4.jpg b/Beispieldateien/Images/dish4.jpg
new file mode 100644
index 0000000..96b9fb1
Binary files /dev/null and b/Beispieldateien/Images/dish4.jpg differ
diff --git a/Beispieldateien/Images/dish5.jpg b/Beispieldateien/Images/dish5.jpg
new file mode 100644
index 0000000..e1d88a6
Binary files /dev/null and b/Beispieldateien/Images/dish5.jpg differ
diff --git a/Beispieldateien/Images/dish6.jpg b/Beispieldateien/Images/dish6.jpg
new file mode 100644
index 0000000..fcd2757
Binary files /dev/null and b/Beispieldateien/Images/dish6.jpg differ
diff --git a/Beispieldateien/Images/dish7.jpg b/Beispieldateien/Images/dish7.jpg
new file mode 100644
index 0000000..9eb85e9
Binary files /dev/null and b/Beispieldateien/Images/dish7.jpg differ
diff --git a/Beispieldateien/Images/dish8.jpg b/Beispieldateien/Images/dish8.jpg
new file mode 100644
index 0000000..b6b9d0b
Binary files /dev/null and b/Beispieldateien/Images/dish8.jpg differ
diff --git a/Beispieldateien/Images/dish9.jpg b/Beispieldateien/Images/dish9.jpg
new file mode 100644
index 0000000..f5f56a0
Binary files /dev/null and b/Beispieldateien/Images/dish9.jpg differ
diff --git a/Beispieldateien/Images/license.md b/Beispieldateien/Images/license.md
new file mode 100644
index 0000000..dfa107d
--- /dev/null
+++ b/Beispieldateien/Images/license.md
@@ -0,0 +1,59 @@
+All pictures are taken from the following sources:
+
+- Pexels
+- Pixabay
+- Pixnio
+- Pxhere
+- Rawpixl
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+ilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Pixnio
+https://pixnio.com/de/
+https://pixnio.com/public-domain-definition
+Hochwertige urheberrechts-freundliche Bilder, urheberrechtsfreie Bilder und Bilder ohne Beschränkung für deren Verwendung. Explizit in der Public Domain platzierte Bilder, keine Rechte vorbehalten. Public Domain Bilder können für beliebige Zwecke genutzt werden, nutzen Sie diese frei für persönliche oder kommerzielle Nutzung.
+
+## Pxhere
+https://pxhere.com/de/license
+
+ It's hard to understand complex licenses that is why all photos on PxHere are licensed under the Creative Commons Zero (CC0) license. This means the pictures are completely free to be used for any legal purpose.
+ The pictures are free for personal and even for commercial use.
+ You can modify, copy and distribute the photos.
+ All without asking for permission or setting a link to the source. So, attribution is not required.
+ The only restriction is that identifiable people may not appear in a bad light or in a way that they may find offensive, unless they give their consent.
+ The CC0 license was released by the non-profit organization Creative Commons (CC). Get more information about Creative Commons images and the license on the official license page.
+
+## Rawpixl
+https://www.rawpixel.com/services/image-licenses
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner.sln b/Kap02/Restschuldrechner/Restschuldrechner.sln
new file mode 100644
index 0000000..b3abaa3
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Restschuldrechner", "Restschuldrechner\Restschuldrechner.csproj", "{915BC78D-E944-48A9-9D9F-82E6D520D5DF}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Release|Any CPU.Build.0 = Release|Any CPU
+ {915BC78D-E944-48A9-9D9F-82E6D520D5DF}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/App.xaml b/Kap02/Restschuldrechner/Restschuldrechner/App.xaml
new file mode 100644
index 0000000..f14aba4
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/App.xaml.cs b/Kap02/Restschuldrechner/Restschuldrechner/App.xaml.cs
new file mode 100644
index 0000000..4a6a672
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace Restschuldrechner;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml b/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml
new file mode 100644
index 0000000..f11feab
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml.cs b/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml.cs
new file mode 100644
index 0000000..160147d
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace Restschuldrechner;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/DoubleConverter.cs b/Kap02/Restschuldrechner/Restschuldrechner/DoubleConverter.cs
new file mode 100644
index 0000000..9bab4df
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/DoubleConverter.cs
@@ -0,0 +1,27 @@
+
+namespace Restschuldrechner
+{
+ public class DoubleConverter : IValueConverter
+ {
+ public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
+ {
+ if (value is double)
+ {
+ return value.ToString();
+ }
+
+ return value;
+ }
+
+ public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
+ {
+ if (double.TryParse(value as string, out double dbl))
+ {
+ return dbl;
+ }
+
+ return value;
+ }
+
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml b/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml
new file mode 100644
index 0000000..4230c34
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml
@@ -0,0 +1,65 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml.cs b/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml.cs
new file mode 100644
index 0000000..5013f87
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/MainPage.xaml.cs
@@ -0,0 +1,45 @@
+namespace Restschuldrechner;
+
+public partial class MainPage : ContentPage
+{
+ public MainPage()
+ {
+ InitializeComponent();
+ this.BindingContext = new RestschuldViewModel();
+ }
+
+ private double _width;
+ private double _height;
+ protected override void OnSizeAllocated(double width, double height)
+ {
+ base.OnSizeAllocated(width, height);
+ if (width != _width || height != _height) // Prüfen, ob sich die Größe geändert hat
+ {
+ _width = width;
+ _height = height;
+
+ if (width > height) // Breite > Höhe = Querformat
+ {
+ OuterLayout.Orientation = StackOrientation.Horizontal;
+
+ // Breite der Kindelemente proportional anpassen
+ foreach (View view in OuterLayout.Children)
+ {
+ view.WidthRequest = width / OuterLayout.Children.Count;
+ }
+ }
+ else
+ {
+ OuterLayout.Orientation = StackOrientation.Vertical;
+
+ // Im Hochformat haben die Kindelemente die gleiche Breite wie das OuterLayout
+ foreach (View view in OuterLayout.Children)
+ {
+ view.WidthRequest = OuterLayout.Width;
+ }
+ }
+ }
+ }
+
+}
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/MauiProgram.cs b/Kap02/Restschuldrechner/Restschuldrechner/MauiProgram.cs
new file mode 100644
index 0000000..3ca49bc
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace Restschuldrechner;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/AndroidManifest.xml b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainActivity.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..e3ff80d
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace Restschuldrechner;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainApplication.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..da876bf
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace Restschuldrechner;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/Resources/values/colors.xml b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/AppDelegate.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..f10202b
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace Restschuldrechner;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Info.plist b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Program.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..3b600c3
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace Restschuldrechner;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/Main.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..a12a4a0
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace Restschuldrechner;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/tizen-manifest.xml b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..bcfb01c
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ appicon.xhigh.png
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..9b6f9fa
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..2b20cf0
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace Restschuldrechner.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/Package.appxmanifest b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/app.manifest b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..c60f0f0
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/AppDelegate.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..f10202b
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace Restschuldrechner;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Info.plist b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Program.cs b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..3b600c3
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace Restschuldrechner;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Properties/launchSettings.json b/Kap02/Restschuldrechner/Restschuldrechner/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appicon.svg b/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appiconfg.svg b/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Regular.ttf b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..2c94413
Binary files /dev/null and b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Semibold.ttf b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..3c54fa7
Binary files /dev/null and b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Images/dotnet_bot.svg b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Raw/AboutAssets.txt b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Splash/splash.svg b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Colors.xaml b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Styles.xaml b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..3b0fdc4
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/RestschuldViewModel.cs b/Kap02/Restschuldrechner/Restschuldrechner/RestschuldViewModel.cs
new file mode 100644
index 0000000..3cc17c8
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/RestschuldViewModel.cs
@@ -0,0 +1,188 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace Restschuldrechner;
+
+public class RestschuldViewModel : INotifyPropertyChanged
+{
+ public event PropertyChangedEventHandler PropertyChanged;
+
+ private double _kreditSumme = 150000;
+ private double _tilgungsSatz = 1.5f;
+ private int _zinsbindung = 15;
+ private double _zinsfuss = 1.5f;
+
+ private double _zahlungen;
+ private double _rsk;
+ private double _tilgung;
+ private double _zinszahlungen;
+ private double _anteilRestschuld;
+
+
+ ///
+ /// Kreditsumme (S)
+ ///
+ public double KreditSumme
+ {
+ get => _kreditSumme;
+ set
+ {
+ if (_kreditSumme == value) { return; }
+ _kreditSumme = value;
+ OnPropertyChanged();
+ Calculate();
+ }
+ }
+
+ ///
+ /// Zinsfuß (p)
+ ///
+ public double Zinsfuss
+ {
+ get => _zinsfuss;
+ set
+ {
+ if (_zinsfuss == value) { return; }
+ _zinsfuss = value;
+ OnPropertyChanged();
+ Calculate();
+ }
+ }
+
+
+ ///
+ /// Tilgungsssatz (t)
+ ///
+ public double TilgungsSatz
+ {
+ get => _tilgungsSatz;
+ set
+ {
+ if (_tilgungsSatz == value) { return; }
+ _tilgungsSatz = value;
+ OnPropertyChanged();
+ Calculate();
+ }
+ }
+
+ ///
+ /// Zinsbindung in Jahren (k)
+ ///
+ public int Zinsbindung
+ {
+ get => _zinsbindung;
+ set
+ {
+ if (_zinsbindung == value) { return; }
+ _zinsbindung = value;
+ OnPropertyChanged();
+ Calculate();
+ }
+ }
+
+ ///
+ /// Anteil der Restschuld an der Gesamtschuld
+ ///
+ public double AnteilRestschuld
+ {
+ get => _anteilRestschuld;
+ set
+ {
+ _anteilRestschuld = Math.Max(0, value);
+ OnPropertyChanged();
+ }
+ }
+
+ ///
+ /// Summe der Zinszahlungen während der Zinsbindung
+ ///
+ public double Zinszahlungen
+ {
+ get => _zinszahlungen;
+ set
+ {
+ _zinszahlungen = value;
+ OnPropertyChanged();
+ }
+ }
+
+ ///
+ /// Höhe der Tilgung während der Zinsbindung
+ ///
+ public double Tilgung
+ {
+ get => _tilgung;
+ set
+ {
+ _tilgung = value;
+ OnPropertyChanged();
+ }
+ }
+
+ ///
+ /// Restschuld am Ende der Laufzeit
+ ///
+ public double Restschuld
+ {
+ get => _rsk;
+ set
+ {
+ _rsk = value;
+ OnPropertyChanged();
+ }
+ }
+
+ ///
+ /// Gesamtzahlungen während der Laufzeit
+ ///
+ public double Zahlungen
+ {
+ get => _zahlungen;
+ set
+ {
+ _zahlungen = value;
+ OnPropertyChanged();
+ }
+ }
+
+
+ private void Calculate()
+ {
+ // Zinssatz pro Jahr (i)
+ var i = Zinsfuss / 100;
+
+ // Zinssatz pro Monat (im)
+ var im = i / 12;
+
+ // Zinsfaktor pro Monat (qm)
+ var qm = im + 1;
+
+ // Zinsbindung in Monaten
+ var km = Zinsbindung * 12;
+
+ // jährliche Annuität (A)
+ var annuitaet = KreditSumme * (i + TilgungsSatz / 100);
+
+ // monatliche Annuität (a)
+ var a = annuitaet / 12;
+
+ // Gesamtzahlungen während der Laufzeit
+ Zahlungen = annuitaet * Zinsbindung;
+
+ // Restschuld am Ende der Laufzeit / Jahr k (RSk)
+ Restschuld = KreditSumme - (Math.Pow(qm, km) - 1) / im * (a - im * KreditSumme);
+
+ // Tilgung
+ Tilgung = KreditSumme - Restschuld;
+ Zinszahlungen = Zahlungen - Tilgung;
+
+ AnteilRestschuld = 250d / KreditSumme * Restschuld;
+
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+
+}
diff --git a/Kap02/Restschuldrechner/Restschuldrechner/Restschuldrechner.csproj b/Kap02/Restschuldrechner/Restschuldrechner/Restschuldrechner.csproj
new file mode 100644
index 0000000..f1a4ede
--- /dev/null
+++ b/Kap02/Restschuldrechner/Restschuldrechner/Restschuldrechner.csproj
@@ -0,0 +1,51 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ Restschuldrechner
+ true
+ true
+ enable
+
+
+ Restschuldrechner
+
+
+ com.companyname.restschuldrechner
+ 23CDEF64-C3C8-42D4-A4AB-0C91B5D26476
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap03/AndroidApp1/AndroidApp1.sln b/Kap03/AndroidApp1/AndroidApp1.sln
new file mode 100644
index 0000000..89d4f88
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32611.2
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AndroidApp1", "AndroidApp1\AndroidApp1.csproj", "{71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Release|Any CPU.Build.0 = Release|Any CPU
+ {71E88FF6-72FF-431A-9CB4-7C35DA47B0FF}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {335F2F91-15C8-4642-8183-8220B323E9D6}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap03/AndroidApp1/AndroidApp1/AndroidApp1.csproj b/Kap03/AndroidApp1/AndroidApp1/AndroidApp1.csproj
new file mode 100644
index 0000000..9461092
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/AndroidApp1.csproj
@@ -0,0 +1,15 @@
+
+
+ net6.0-android
+ 21
+ Exe
+ enable
+ enable
+ com.companyname.AndroidApp1
+ 1
+ 1.0
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/AndroidManifest.xml b/Kap03/AndroidApp1/AndroidApp1/AndroidManifest.xml
new file mode 100644
index 0000000..1811bb4
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Assets/readme.txt b/Kap03/AndroidApp1/AndroidApp1/Assets/readme.txt
new file mode 100644
index 0000000..6de3577
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Assets/readme.txt
@@ -0,0 +1 @@
+Demo Asset
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/MainActivity.cs b/Kap03/AndroidApp1/AndroidApp1/MainActivity.cs
new file mode 100644
index 0000000..34b8563
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/MainActivity.cs
@@ -0,0 +1,13 @@
+namespace AndroidApp1
+{
+ [Activity(Label = "@string/app_name", MainLauncher = true)]
+ public class MainActivity : Activity
+ {
+ protected override void OnCreate(Bundle? savedInstanceState)
+ {
+ base.OnCreate(savedInstanceState);
+ // Set our view from the "main" layout resource
+ SetContentView(Resource.Layout.activity_main);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/AboutResources.txt b/Kap03/AndroidApp1/AndroidApp1/Resources/AboutResources.txt
new file mode 100644
index 0000000..219f425
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/AboutResources.txt
@@ -0,0 +1,44 @@
+Images, layout descriptions, binary blobs and string dictionaries can be included
+in your application as resource files. Various Android APIs are designed to
+operate on the resource IDs instead of dealing with images, strings or binary blobs
+directly.
+
+For example, a sample Android app that contains a user interface layout (main.xml),
+an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png)
+would keep its resources in the "Resources" directory of the application:
+
+Resources/
+ drawable/
+ icon.png
+
+ layout/
+ main.xml
+
+ values/
+ strings.xml
+
+In order to get the build system to recognize Android resources, set the build action to
+"AndroidResource". The native Android APIs do not operate directly with filenames, but
+instead operate on resource IDs. When you compile an Android application that uses resources,
+the build system will package the resources for distribution and generate a class called "Resource"
+(this is an Android convention) that contains the tokens for each one of the resources
+included. For example, for the above Resources layout, this is what the Resource class would expose:
+
+public class Resource {
+ public class Drawable {
+ public const int icon = 0x123;
+ }
+
+ public class Layout {
+ public const int main = 0x456;
+ }
+
+ public class Strings {
+ public const int first_string = 0xabc;
+ public const int second_string = 0xbcd;
+ }
+}
+
+You would then use Resource.Drawable.icon to reference the drawable/icon.png file, or
+Resource.Layout.main to reference the layout/main.xml file, or Resource.Strings.first_string
+to reference the first string in the dictionary file values/strings.xml.
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/layout/activity_main.xml b/Kap03/AndroidApp1/AndroidApp1/Resources/layout/activity_main.xml
new file mode 100644
index 0000000..f949852
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/layout/activity_main.xml
@@ -0,0 +1,13 @@
+
+
+
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher.xml b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher.xml
new file mode 100644
index 0000000..036d09b
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher_round.xml b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher_round.xml
new file mode 100644
index 0000000..036d09b
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-anydpi-v26/ic_launcher_round.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher.png
new file mode 100644
index 0000000..2531cb3
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_foreground.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_foreground.png
new file mode 100644
index 0000000..7a859c2
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_foreground.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_round.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_round.png
new file mode 100644
index 0000000..b8d35b3
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-hdpi/ic_launcher_round.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher.png
new file mode 100644
index 0000000..795ea7c
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_foreground.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_foreground.png
new file mode 100644
index 0000000..a12b157
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_foreground.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_round.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_round.png
new file mode 100644
index 0000000..8f56909
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-mdpi/ic_launcher_round.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher.png
new file mode 100644
index 0000000..761cc91
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_foreground.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_foreground.png
new file mode 100644
index 0000000..e7d70a5
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_foreground.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_round.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..9737d79
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xhdpi/ic_launcher_round.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher.png
new file mode 100644
index 0000000..9133e31
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_foreground.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_foreground.png
new file mode 100644
index 0000000..73ccaa6
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_foreground.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_round.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..c3ae5f5
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxhdpi/ic_launcher_round.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher.png
new file mode 100644
index 0000000..d4fd714
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_foreground.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_foreground.png
new file mode 100644
index 0000000..f6584af
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_foreground.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_round.png b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..ef89bd5
Binary files /dev/null and b/Kap03/AndroidApp1/AndroidApp1/Resources/mipmap-xxxhdpi/ic_launcher_round.png differ
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/values/ic_launcher_background.xml b/Kap03/AndroidApp1/AndroidApp1/Resources/values/ic_launcher_background.xml
new file mode 100644
index 0000000..6ec24e6
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/values/ic_launcher_background.xml
@@ -0,0 +1,4 @@
+
+
+ #2C3E50
+
\ No newline at end of file
diff --git a/Kap03/AndroidApp1/AndroidApp1/Resources/values/strings.xml b/Kap03/AndroidApp1/AndroidApp1/Resources/values/strings.xml
new file mode 100644
index 0000000..17f62c7
--- /dev/null
+++ b/Kap03/AndroidApp1/AndroidApp1/Resources/values/strings.xml
@@ -0,0 +1,4 @@
+
+ AndroidApp1
+ Hello, Android!
+
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1.sln b/Kap04/MacCatalystApp1/MacCatalystApp1.sln
new file mode 100644
index 0000000..884f5a4
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1.sln
@@ -0,0 +1,25 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32611.2
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MacCatalystApp1", "MacCatalystApp1\MacCatalystApp1.csproj", "{CD9596E8-FD7B-46D4-869C-83F49CA9C168}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {CD9596E8-FD7B-46D4-869C-83F49CA9C168}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {CD9596E8-FD7B-46D4-869C-83F49CA9C168}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {CD9596E8-FD7B-46D4-869C-83F49CA9C168}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {CD9596E8-FD7B-46D4-869C-83F49CA9C168}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {5A4ADACA-8446-4165-AA85-13984B3C26FA}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/AppDelegate.cs b/Kap04/MacCatalystApp1/MacCatalystApp1/AppDelegate.cs
new file mode 100644
index 0000000..62cd855
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/AppDelegate.cs
@@ -0,0 +1,34 @@
+namespace MacCatalystApp1
+{
+ [Register("AppDelegate")]
+ public class AppDelegate : UIApplicationDelegate
+ {
+ public override UIWindow? Window
+ {
+ get;
+ set;
+ }
+
+ public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
+ {
+ // create a new window instance based on the screen size
+ Window = new UIWindow(UIScreen.MainScreen.Bounds);
+
+ // create a UIViewController with a single UILabel
+ var vc = new UIViewController();
+ vc.View!.AddSubview(new UILabel(Window!.Frame)
+ {
+ BackgroundColor = UIColor.SystemBackground,
+ TextAlignment = UITextAlignment.Center,
+ Text = "Hello, Catalyst!",
+ AutoresizingMask = UIViewAutoresizing.All,
+ });
+ Window.RootViewController = vc;
+
+ // make the window visible
+ Window.MakeKeyAndVisible();
+
+ return true;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Contents.json b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Contents.json
new file mode 100644
index 0000000..2242b9a
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Contents.json
@@ -0,0 +1,68 @@
+{
+ "images": [
+ {
+ "idiom" : "mac",
+ "scale" : "1x",
+ "size" : "16x16",
+ "filename": "Icon16.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "2x",
+ "size" : "16x16",
+ "filename": "Icon32.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "1x",
+ "size" : "32x32",
+ "filename": "Icon32.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "2x",
+ "size" : "32x32",
+ "filename": "Icon64.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "1x",
+ "size" : "128x128",
+ "filename": "Icon128.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "2x",
+ "size" : "128x128",
+ "filename": "Icon256.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "1x",
+ "size" : "256x256",
+ "filename": "Icon256.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "2x",
+ "size" : "256x256",
+ "filename": "Icon512.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "1x",
+ "size" : "512x512",
+ "filename": "Icon512.png"
+ },
+ {
+ "idiom" : "mac",
+ "scale" : "2x",
+ "size" : "512x512",
+ "filename": "Icon1024.png"
+ }
+ ],
+ "info": {
+ "version": 1,
+ "author": "xcode"
+ },
+}
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png
new file mode 100644
index 0000000..9174c98
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon128.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon128.png
new file mode 100644
index 0000000..9c87846
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon128.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon16.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon16.png
new file mode 100644
index 0000000..35c074e
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon16.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon256.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon256.png
new file mode 100644
index 0000000..7195407
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon256.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon32.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon32.png
new file mode 100644
index 0000000..a488140
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon32.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon512.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon512.png
new file mode 100644
index 0000000..640e594
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon512.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon64.png b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon64.png
new file mode 100644
index 0000000..4027b6b
Binary files /dev/null and b/Kap04/MacCatalystApp1/MacCatalystApp1/Assets.xcassets/AppIcon.appiconset/Icon64.png differ
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Entitlements.plist b/Kap04/MacCatalystApp1/MacCatalystApp1/Entitlements.plist
new file mode 100644
index 0000000..36a8706
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/Entitlements.plist
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Info.plist b/Kap04/MacCatalystApp1/MacCatalystApp1/Info.plist
new file mode 100644
index 0000000..f7cfc04
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/Info.plist
@@ -0,0 +1,26 @@
+
+
+
+
+ CFBundleDisplayName
+ MacCatalystApp1
+ CFBundleIdentifier
+ com.companyname.MacCatalystApp1
+ CFBundleShortVersionString
+ 1.0
+ CFBundleVersion
+ 1.0
+ UIDeviceFamily
+
+ 2
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/AppIcon.appiconset
+
+
\ No newline at end of file
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/MacCatalystApp1.csproj b/Kap04/MacCatalystApp1/MacCatalystApp1/MacCatalystApp1.csproj
new file mode 100644
index 0000000..83ff876
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/MacCatalystApp1.csproj
@@ -0,0 +1,10 @@
+
+
+ net6.0-maccatalyst
+ maccatalyst-x64
+ Exe
+ enable
+ true
+ 14.2
+
+
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Main.cs b/Kap04/MacCatalystApp1/MacCatalystApp1/Main.cs
new file mode 100644
index 0000000..046584b
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/Main.cs
@@ -0,0 +1,6 @@
+using MacCatalystApp1;
+
+// This is the main entry point of the application.
+// If you want to use a different Application Delegate class from "AppDelegate"
+// you can specify it here.
+UIApplication.Main(args, null, typeof(AppDelegate));
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/Resources/LaunchScreen.xib b/Kap04/MacCatalystApp1/MacCatalystApp1/Resources/LaunchScreen.xib
new file mode 100644
index 0000000..8190201
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/Resources/LaunchScreen.xib
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap04/MacCatalystApp1/MacCatalystApp1/SceneDelegate.cs b/Kap04/MacCatalystApp1/MacCatalystApp1/SceneDelegate.cs
new file mode 100644
index 0000000..c725bde
--- /dev/null
+++ b/Kap04/MacCatalystApp1/MacCatalystApp1/SceneDelegate.cs
@@ -0,0 +1,56 @@
+namespace MacCatalystApp1
+{
+ [Register("SceneDelegate")]
+ public class SceneDelegate : UIResponder, IUIWindowSceneDelegate
+ {
+
+ [Export("window")]
+ public UIWindow? Window { get; set; }
+
+ [Export("scene:willConnectToSession:options:")]
+ public void WillConnect(UIScene scene, UISceneSession session, UISceneConnectionOptions connectionOptions)
+ {
+ // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
+ // If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
+ // This delegate does not imply the connecting scene or session are new (see UIApplicationDelegate `GetConfiguration` instead).
+ }
+
+ [Export("sceneDidDisconnect:")]
+ public void DidDisconnect(UIScene scene)
+ {
+ // Called as the scene is being released by the system.
+ // This occurs shortly after the scene enters the background, or when its session is discarded.
+ // Release any resources associated with this scene that can be re-created the next time the scene connects.
+ // The scene may re-connect later, as its session was not neccessarily discarded (see UIApplicationDelegate `DidDiscardSceneSessions` instead).
+ }
+
+ [Export("sceneDidBecomeActive:")]
+ public void DidBecomeActive(UIScene scene)
+ {
+ // Called when the scene has moved from an inactive state to an active state.
+ // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
+ }
+
+ [Export("sceneWillResignActive:")]
+ public void WillResignActive(UIScene scene)
+ {
+ // Called when the scene will move from an active state to an inactive state.
+ // This may occur due to temporary interruptions (ex. an incoming phone call).
+ }
+
+ [Export("sceneWillEnterForeground:")]
+ public void WillEnterForeground(UIScene scene)
+ {
+ // Called as the scene transitions from the background to the foreground.
+ // Use this method to undo the changes made on entering the background.
+ }
+
+ [Export("sceneDidEnterBackground:")]
+ public void DidEnterBackground(UIScene scene)
+ {
+ // Called as the scene transitions from the foreground to the background.
+ // Use this method to save data, release shared resources, and store enough scene-specific state information
+ // to restore the scene back to its current state.
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap04/iOSApp1/iOSApp1.sln b/Kap04/iOSApp1/iOSApp1.sln
new file mode 100644
index 0000000..bb81fe4
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32611.2
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "iOSApp1", "iOSApp1\iOSApp1.csproj", "{B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Release|Any CPU.Build.0 = Release|Any CPU
+ {B59F1F59-1ACF-403D-B9D1-AD95C0D67E8D}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {08EE4998-0AD2-4E50-BEED-B0C29B0CCED8}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap04/iOSApp1/iOSApp1/AppDelegate.cs b/Kap04/iOSApp1/iOSApp1/AppDelegate.cs
new file mode 100644
index 0000000..b3ce3a2
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/AppDelegate.cs
@@ -0,0 +1,34 @@
+namespace iOSApp1
+{
+ [Register("AppDelegate")]
+ public class AppDelegate : UIApplicationDelegate
+ {
+ public override UIWindow? Window
+ {
+ get;
+ set;
+ }
+
+ public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
+ {
+ // create a new window instance based on the screen size
+ Window = new UIWindow(UIScreen.MainScreen.Bounds);
+
+ // create a UIViewController with a single UILabel
+ var vc = new UIViewController();
+ vc.View!.AddSubview(new UILabel(Window!.Frame)
+ {
+ BackgroundColor = UIColor.SystemBackground,
+ TextAlignment = UITextAlignment.Center,
+ Text = "Hello, iOS!",
+ AutoresizingMask = UIViewAutoresizing.All,
+ });
+ Window.RootViewController = vc;
+
+ // make the window visible
+ Window.MakeKeyAndVisible();
+
+ return true;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Contents.json b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Contents.json
new file mode 100644
index 0000000..98f4d03
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Contents.json
@@ -0,0 +1,117 @@
+{
+ "images": [
+ {
+ "scale": "2x",
+ "size": "20x20",
+ "idiom": "iphone",
+ "filename": "Icon40.png"
+ },
+ {
+ "scale": "3x",
+ "size": "20x20",
+ "idiom": "iphone",
+ "filename": "Icon60.png"
+ },
+ {
+ "scale": "2x",
+ "size": "29x29",
+ "idiom": "iphone",
+ "filename": "Icon58.png"
+ },
+ {
+ "scale": "3x",
+ "size": "29x29",
+ "idiom": "iphone",
+ "filename": "Icon87.png"
+ },
+ {
+ "scale": "2x",
+ "size": "40x40",
+ "idiom": "iphone",
+ "filename": "Icon80.png"
+ },
+ {
+ "scale": "3x",
+ "size": "40x40",
+ "idiom": "iphone",
+ "filename": "Icon120.png"
+ },
+ {
+ "scale": "2x",
+ "size": "60x60",
+ "idiom": "iphone",
+ "filename": "Icon120.png"
+ },
+ {
+ "scale": "3x",
+ "size": "60x60",
+ "idiom": "iphone",
+ "filename": "Icon180.png"
+ },
+ {
+ "scale": "1x",
+ "size": "20x20",
+ "idiom": "ipad",
+ "filename": "Icon20.png"
+ },
+ {
+ "scale": "2x",
+ "size": "20x20",
+ "idiom": "ipad",
+ "filename": "Icon40.png"
+ },
+ {
+ "scale": "1x",
+ "size": "29x29",
+ "idiom": "ipad",
+ "filename": "Icon29.png"
+ },
+ {
+ "scale": "2x",
+ "size": "29x29",
+ "idiom": "ipad",
+ "filename": "Icon58.png"
+ },
+ {
+ "scale": "1x",
+ "size": "40x40",
+ "idiom": "ipad",
+ "filename": "Icon40.png"
+ },
+ {
+ "scale": "2x",
+ "size": "40x40",
+ "idiom": "ipad",
+ "filename": "Icon80.png"
+ },
+ {
+ "scale": "1x",
+ "size": "76x76",
+ "idiom": "ipad",
+ "filename": "Icon76.png"
+ },
+ {
+ "scale": "2x",
+ "size": "76x76",
+ "idiom": "ipad",
+ "filename": "Icon152.png"
+ },
+ {
+ "scale": "2x",
+ "size": "83.5x83.5",
+ "idiom": "ipad",
+ "filename": "Icon167.png"
+ },
+ {
+ "scale": "1x",
+ "size": "1024x1024",
+ "idiom": "ios-marketing",
+ "filename": "Icon1024.png"
+ }
+ ],
+ "properties": {},
+ "info": {
+ "version": 1,
+ "author": "xcode"
+ }
+}
\ No newline at end of file
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png
new file mode 100644
index 0000000..9174c98
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon1024.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon120.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon120.png
new file mode 100644
index 0000000..9c60a17
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon120.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon152.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon152.png
new file mode 100644
index 0000000..448d6ef
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon152.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon167.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon167.png
new file mode 100644
index 0000000..8524768
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon167.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon180.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon180.png
new file mode 100644
index 0000000..60a6470
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon180.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon20.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon20.png
new file mode 100644
index 0000000..45268a6
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon20.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon29.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon29.png
new file mode 100644
index 0000000..6a6c77a
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon29.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon40.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon40.png
new file mode 100644
index 0000000..cc7edcf
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon40.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon58.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon58.png
new file mode 100644
index 0000000..1ad04f0
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon58.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon60.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon60.png
new file mode 100644
index 0000000..2dd5262
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon60.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon76.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon76.png
new file mode 100644
index 0000000..b058cae
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon76.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon80.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon80.png
new file mode 100644
index 0000000..02e47a2
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon80.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon87.png b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon87.png
new file mode 100644
index 0000000..4954a4b
Binary files /dev/null and b/Kap04/iOSApp1/iOSApp1/Assets.xcassets/AppIcon.appiconset/Icon87.png differ
diff --git a/Kap04/iOSApp1/iOSApp1/Entitlements.plist b/Kap04/iOSApp1/iOSApp1/Entitlements.plist
new file mode 100644
index 0000000..36a8706
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/Entitlements.plist
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/Kap04/iOSApp1/iOSApp1/Info.plist b/Kap04/iOSApp1/iOSApp1/Info.plist
new file mode 100644
index 0000000..c99894c
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/Info.plist
@@ -0,0 +1,42 @@
+
+
+
+
+ CFBundleDisplayName
+ iOSApp1
+ CFBundleIdentifier
+ com.companyname.iOSApp1
+ CFBundleShortVersionString
+ 1.0
+ CFBundleVersion
+ 1.0
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UILaunchStoryboardName
+ LaunchScreen
+ UIRequiredDeviceCapabilities
+
+ armv7
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/AppIcon.appiconset
+
+
diff --git a/Kap04/iOSApp1/iOSApp1/LaunchScreen.storyboard b/Kap04/iOSApp1/iOSApp1/LaunchScreen.storyboard
new file mode 100644
index 0000000..2296c6b
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/LaunchScreen.storyboard
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap04/iOSApp1/iOSApp1/Main.cs b/Kap04/iOSApp1/iOSApp1/Main.cs
new file mode 100644
index 0000000..24e60b7
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/Main.cs
@@ -0,0 +1,6 @@
+using iOSApp1;
+
+// This is the main entry point of the application.
+// If you want to use a different Application Delegate class from "AppDelegate"
+// you can specify it here.
+UIApplication.Main(args, null, typeof(AppDelegate));
diff --git a/Kap04/iOSApp1/iOSApp1/Resources/LaunchScreen.xib b/Kap04/iOSApp1/iOSApp1/Resources/LaunchScreen.xib
new file mode 100644
index 0000000..8190201
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/Resources/LaunchScreen.xib
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap04/iOSApp1/iOSApp1/SceneDelegate.cs b/Kap04/iOSApp1/iOSApp1/SceneDelegate.cs
new file mode 100644
index 0000000..3ecdb93
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/SceneDelegate.cs
@@ -0,0 +1,56 @@
+namespace iOSApp1
+{
+ [Register("SceneDelegate")]
+ public class SceneDelegate : UIResponder, IUIWindowSceneDelegate
+ {
+
+ [Export("window")]
+ public UIWindow? Window { get; set; }
+
+ [Export("scene:willConnectToSession:options:")]
+ public void WillConnect(UIScene scene, UISceneSession session, UISceneConnectionOptions connectionOptions)
+ {
+ // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
+ // If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
+ // This delegate does not imply the connecting scene or session are new (see UIApplicationDelegate `GetConfiguration` instead).
+ }
+
+ [Export("sceneDidDisconnect:")]
+ public void DidDisconnect(UIScene scene)
+ {
+ // Called as the scene is being released by the system.
+ // This occurs shortly after the scene enters the background, or when its session is discarded.
+ // Release any resources associated with this scene that can be re-created the next time the scene connects.
+ // The scene may re-connect later, as its session was not neccessarily discarded (see UIApplicationDelegate `DidDiscardSceneSessions` instead).
+ }
+
+ [Export("sceneDidBecomeActive:")]
+ public void DidBecomeActive(UIScene scene)
+ {
+ // Called when the scene has moved from an inactive state to an active state.
+ // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
+ }
+
+ [Export("sceneWillResignActive:")]
+ public void WillResignActive(UIScene scene)
+ {
+ // Called when the scene will move from an active state to an inactive state.
+ // This may occur due to temporary interruptions (ex. an incoming phone call).
+ }
+
+ [Export("sceneWillEnterForeground:")]
+ public void WillEnterForeground(UIScene scene)
+ {
+ // Called as the scene transitions from the background to the foreground.
+ // Use this method to undo the changes made on entering the background.
+ }
+
+ [Export("sceneDidEnterBackground:")]
+ public void DidEnterBackground(UIScene scene)
+ {
+ // Called as the scene transitions from the foreground to the background.
+ // Use this method to save data, release shared resources, and store enough scene-specific state information
+ // to restore the scene back to its current state.
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap04/iOSApp1/iOSApp1/iOSApp1.csproj b/Kap04/iOSApp1/iOSApp1/iOSApp1.csproj
new file mode 100644
index 0000000..0b5f13a
--- /dev/null
+++ b/Kap04/iOSApp1/iOSApp1/iOSApp1.csproj
@@ -0,0 +1,22 @@
+
+
+ net6.0-ios
+ Exe
+ enable
+ true
+ 13.0
+ automatic
+ Apple Development: André Krämer (GM64FQT723)
+ VS: WildCard Development
+
+
+ Apple Development: André Krämer (GM64FQT723)
+ VS: WildCard Development
+
+
+ False
+
+
+ False
+
+
diff --git a/Kap05/App1/App1.sln b/Kap05/App1/App1.sln
new file mode 100644
index 0000000..8d2ed2a
--- /dev/null
+++ b/Kap05/App1/App1.sln
@@ -0,0 +1,51 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32611.2
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "App1", "App1\App1.csproj", "{020C3E57-78A9-421E-9FD6-45CF3BF39310}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Debug|arm64 = Debug|arm64
+ Debug|x64 = Debug|x64
+ Debug|x86 = Debug|x86
+ Release|Any CPU = Release|Any CPU
+ Release|arm64 = Release|arm64
+ Release|x64 = Release|x64
+ Release|x86 = Release|x86
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|Any CPU.ActiveCfg = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|Any CPU.Build.0 = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|Any CPU.Deploy.0 = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|arm64.ActiveCfg = Debug|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|arm64.Build.0 = Debug|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|arm64.Deploy.0 = Debug|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x64.ActiveCfg = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x64.Build.0 = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x64.Deploy.0 = Debug|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x86.ActiveCfg = Debug|x86
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x86.Build.0 = Debug|x86
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Debug|x86.Deploy.0 = Debug|x86
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|Any CPU.ActiveCfg = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|Any CPU.Build.0 = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|Any CPU.Deploy.0 = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|arm64.ActiveCfg = Release|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|arm64.Build.0 = Release|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|arm64.Deploy.0 = Release|arm64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x64.ActiveCfg = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x64.Build.0 = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x64.Deploy.0 = Release|x64
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x86.ActiveCfg = Release|x86
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x86.Build.0 = Release|x86
+ {020C3E57-78A9-421E-9FD6-45CF3BF39310}.Release|x86.Deploy.0 = Release|x86
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {86D86C17-ED14-43E1-94F2-837CC3A76BB6}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap05/App1/App1/App.xaml b/Kap05/App1/App1/App.xaml
new file mode 100644
index 0000000..c9404c7
--- /dev/null
+++ b/Kap05/App1/App1/App.xaml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap05/App1/App1/App.xaml.cs b/Kap05/App1/App1/App.xaml.cs
new file mode 100644
index 0000000..d27fa24
--- /dev/null
+++ b/Kap05/App1/App1/App.xaml.cs
@@ -0,0 +1,51 @@
+using Microsoft.UI.Xaml;
+using Microsoft.UI.Xaml.Controls;
+using Microsoft.UI.Xaml.Controls.Primitives;
+using Microsoft.UI.Xaml.Data;
+using Microsoft.UI.Xaml.Input;
+using Microsoft.UI.Xaml.Media;
+using Microsoft.UI.Xaml.Navigation;
+using Microsoft.UI.Xaml.Shapes;
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Runtime.InteropServices.WindowsRuntime;
+using Windows.ApplicationModel;
+using Windows.ApplicationModel.Activation;
+using Windows.Foundation;
+using Windows.Foundation.Collections;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace App1
+{
+ ///
+ /// Provides application-specific behavior to supplement the default Application class.
+ ///
+ public partial class App : Application
+ {
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ ///
+ /// Invoked when the application is launched normally by the end user. Other entry points
+ /// will be used such as when the application is launched to open a specific file.
+ ///
+ /// Details about the launch request and process.
+ protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args)
+ {
+ m_window = new MainWindow();
+ m_window.Activate();
+ }
+
+ private Window m_window;
+ }
+}
diff --git a/Kap05/App1/App1/App1.csproj b/Kap05/App1/App1/App1.csproj
new file mode 100644
index 0000000..bd32a3f
--- /dev/null
+++ b/Kap05/App1/App1/App1.csproj
@@ -0,0 +1,49 @@
+
+
+ WinExe
+ net6.0-windows10.0.19041.0
+ 10.0.17763.0
+ App1
+ app.manifest
+ x86;x64;arm64
+ win10-x86;win10-x64;win10-arm64
+ win10-$(Platform).pubxml
+ true
+ true
+ de
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ true
+
+
diff --git a/Kap05/App1/App1/Assets/LockScreenLogo.scale-200.png b/Kap05/App1/App1/Assets/LockScreenLogo.scale-200.png
new file mode 100644
index 0000000..7440f0d
Binary files /dev/null and b/Kap05/App1/App1/Assets/LockScreenLogo.scale-200.png differ
diff --git a/Kap05/App1/App1/Assets/SplashScreen.scale-200.png b/Kap05/App1/App1/Assets/SplashScreen.scale-200.png
new file mode 100644
index 0000000..32f486a
Binary files /dev/null and b/Kap05/App1/App1/Assets/SplashScreen.scale-200.png differ
diff --git a/Kap05/App1/App1/Assets/Square150x150Logo.scale-200.png b/Kap05/App1/App1/Assets/Square150x150Logo.scale-200.png
new file mode 100644
index 0000000..53ee377
Binary files /dev/null and b/Kap05/App1/App1/Assets/Square150x150Logo.scale-200.png differ
diff --git a/Kap05/App1/App1/Assets/Square44x44Logo.scale-200.png b/Kap05/App1/App1/Assets/Square44x44Logo.scale-200.png
new file mode 100644
index 0000000..f713bba
Binary files /dev/null and b/Kap05/App1/App1/Assets/Square44x44Logo.scale-200.png differ
diff --git a/Kap05/App1/App1/Assets/Square44x44Logo.targetsize-24_altform-unplated.png b/Kap05/App1/App1/Assets/Square44x44Logo.targetsize-24_altform-unplated.png
new file mode 100644
index 0000000..dc9f5be
Binary files /dev/null and b/Kap05/App1/App1/Assets/Square44x44Logo.targetsize-24_altform-unplated.png differ
diff --git a/Kap05/App1/App1/Assets/StoreLogo.png b/Kap05/App1/App1/Assets/StoreLogo.png
new file mode 100644
index 0000000..a4586f2
Binary files /dev/null and b/Kap05/App1/App1/Assets/StoreLogo.png differ
diff --git a/Kap05/App1/App1/Assets/Wide310x150Logo.scale-200.png b/Kap05/App1/App1/Assets/Wide310x150Logo.scale-200.png
new file mode 100644
index 0000000..8b4a5d0
Binary files /dev/null and b/Kap05/App1/App1/Assets/Wide310x150Logo.scale-200.png differ
diff --git a/Kap05/App1/App1/MainWindow.xaml b/Kap05/App1/App1/MainWindow.xaml
new file mode 100644
index 0000000..78c6eab
--- /dev/null
+++ b/Kap05/App1/App1/MainWindow.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
diff --git a/Kap05/App1/App1/MainWindow.xaml.cs b/Kap05/App1/App1/MainWindow.xaml.cs
new file mode 100644
index 0000000..d69ad72
--- /dev/null
+++ b/Kap05/App1/App1/MainWindow.xaml.cs
@@ -0,0 +1,36 @@
+using Microsoft.UI.Xaml;
+using Microsoft.UI.Xaml.Controls;
+using Microsoft.UI.Xaml.Controls.Primitives;
+using Microsoft.UI.Xaml.Data;
+using Microsoft.UI.Xaml.Input;
+using Microsoft.UI.Xaml.Media;
+using Microsoft.UI.Xaml.Navigation;
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Runtime.InteropServices.WindowsRuntime;
+using Windows.Foundation;
+using Windows.Foundation.Collections;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace App1
+{
+ ///
+ /// An empty window that can be used on its own or navigated to within a Frame.
+ ///
+ public sealed partial class MainWindow : Window
+ {
+ public MainWindow()
+ {
+ this.InitializeComponent();
+ }
+
+ private void myButton_Click(object sender, RoutedEventArgs e)
+ {
+ myButton.Content = "Clicked";
+ }
+ }
+}
diff --git a/Kap05/App1/App1/Package.appxmanifest b/Kap05/App1/App1/Package.appxmanifest
new file mode 100644
index 0000000..2b1f49a
--- /dev/null
+++ b/Kap05/App1/App1/Package.appxmanifest
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+ App1
+ AndréKrämer
+ Assets\StoreLogo.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap05/App1/App1/Properties/launchSettings.json b/Kap05/App1/App1/Properties/launchSettings.json
new file mode 100644
index 0000000..c7779fb
--- /dev/null
+++ b/Kap05/App1/App1/Properties/launchSettings.json
@@ -0,0 +1,10 @@
+{
+ "profiles": {
+ "App1 (Package)": {
+ "commandName": "MsixPackage"
+ },
+ "App1 (Unpackaged)": {
+ "commandName": "Project"
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap05/App1/App1/app.manifest b/Kap05/App1/App1/app.manifest
new file mode 100644
index 0000000..ab25dab
--- /dev/null
+++ b/Kap05/App1/App1/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo.sln b/Kap06/Kapitel6Demo/Kapitel6Demo.sln
new file mode 100644
index 0000000..e90faf6
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Kapitel6Demo", "Kapitel6Demo\Kapitel6Demo.csproj", "{39CDDBB3-CDDA-4906-9462-B8067933FC0A}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Release|Any CPU.Build.0 = Release|Any CPU
+ {39CDDBB3-CDDA-4906-9462-B8067933FC0A}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml
new file mode 100644
index 0000000..42776b8
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml.cs
new file mode 100644
index 0000000..d2bd9de
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace Kapitel6Demo;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml
new file mode 100644
index 0000000..be2e422
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml.cs
new file mode 100644
index 0000000..0ba2b4a
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace Kapitel6Demo;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Kapitel6Demo.csproj b/Kap06/Kapitel6Demo/Kapitel6Demo/Kapitel6Demo.csproj
new file mode 100644
index 0000000..4a0530c
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Kapitel6Demo.csproj
@@ -0,0 +1,51 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ Kapitel6Demo
+ true
+ true
+ enable
+
+
+ Kapitel6Demo
+
+
+ com.companyname.kapitel6demo
+ EB5DA37B-14C4-432E-BD1B-F5651C859CD5
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml
new file mode 100644
index 0000000..02d9900
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml.cs
new file mode 100644
index 0000000..fc9e4ac
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace Kapitel6Demo;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/MauiProgram.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/MauiProgram.cs
new file mode 100644
index 0000000..9bbde0b
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace Kapitel6Demo;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/AndroidManifest.xml b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainActivity.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..c564ffe
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace Kapitel6Demo;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainApplication.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..3af6316
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace Kapitel6Demo;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/Resources/values/colors.xml b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/AppDelegate.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..52237ba
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace Kapitel6Demo;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Info.plist b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Program.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..590be15
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace Kapitel6Demo;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/Main.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..aa82502
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace Kapitel6Demo;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/tizen-manifest.xml b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..9b1e841
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..1502cdb
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..9436fa8
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace Kapitel6Demo.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/Package.appxmanifest b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/app.manifest b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..f2ac285
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/AppDelegate.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..52237ba
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace Kapitel6Demo;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Info.plist b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Program.cs b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..590be15
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace Kapitel6Demo;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Properties/launchSettings.json b/Kap06/Kapitel6Demo/Kapitel6Demo/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appicon.svg b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appiconfg.svg b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Regular.ttf b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Semibold.ttf b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Images/dotnet_bot.svg b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Raw/AboutAssets.txt b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Splash/splash.svg b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Colors.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Styles.xaml b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap06/Kapitel6Demo/Kapitel6Demo/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo.sln b/Kap06/MauiDemo/MauiDemo.sln
new file mode 100644
index 0000000..2999a09
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.3.32611.2
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MauiDemo", "MauiDemo\MauiDemo.csproj", "{56E56434-1BFB-4042-9584-5C1D79C9A7D4}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Release|Any CPU.Build.0 = Release|Any CPU
+ {56E56434-1BFB-4042-9584-5C1D79C9A7D4}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {41491284-6F0A-4753-84D0-85491DB823CD}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap06/MauiDemo/MauiDemo/App.xaml b/Kap06/MauiDemo/MauiDemo/App.xaml
new file mode 100644
index 0000000..8daa73d
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/App.xaml.cs b/Kap06/MauiDemo/MauiDemo/App.xaml.cs
new file mode 100644
index 0000000..a0c6785
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/App.xaml.cs
@@ -0,0 +1,13 @@
+namespace MauiDemo
+{
+ public partial class App : Application
+ {
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/AppShell.xaml b/Kap06/MauiDemo/MauiDemo/AppShell.xaml
new file mode 100644
index 0000000..c1e75af
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/AppShell.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/AppShell.xaml.cs b/Kap06/MauiDemo/MauiDemo/AppShell.xaml.cs
new file mode 100644
index 0000000..50cbb49
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/AppShell.xaml.cs
@@ -0,0 +1,10 @@
+namespace MauiDemo
+{
+ public partial class AppShell : Shell
+ {
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/MainPage.xaml b/Kap06/MauiDemo/MauiDemo/MainPage.xaml
new file mode 100644
index 0000000..ac5771f
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MainPage.xaml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/MainPage.xaml.cs b/Kap06/MauiDemo/MauiDemo/MainPage.xaml.cs
new file mode 100644
index 0000000..b9369a1
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MainPage.xaml.cs
@@ -0,0 +1,11 @@
+namespace MauiDemo
+{
+ public partial class MainPage : ContentPage
+ {
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/MainPageCs.cs b/Kap06/MauiDemo/MauiDemo/MainPageCs.cs
new file mode 100644
index 0000000..95e7256
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MainPageCs.cs
@@ -0,0 +1,54 @@
+using Microsoft.Maui.Controls.Shapes;
+namespace MauiDemo;
+
+public class MainPageCs : ContentPage
+{
+ public MainPageCs()
+ {
+ Title = "Login via C#";
+ BackgroundColor = Color.FromArgb("#f0f1f7");
+
+ var outerStackLayout = new VerticalStackLayout();
+ outerStackLayout.Spacing = 25;
+ outerStackLayout.Padding = 30;
+
+ var headerLabel = new Label();
+ headerLabel.FontSize = 20;
+ headerLabel.Text = "Herzlich Willkommen zur .NET-MAUI-Demo";
+ outerStackLayout.Children.Add(headerLabel);
+
+ var border = new Border();
+ border.BackgroundColor = Colors.White;
+ border.Stroke = Colors.White;
+ var roundRectangle = new RoundRectangle();
+ roundRectangle.CornerRadius = new CornerRadius(10, 10, 10, 10);
+ border.StrokeShape = roundRectangle;
+ border.Padding = 20;
+
+ var loginStackLayout = new VerticalStackLayout();
+ loginStackLayout.Spacing = 15;
+ var userLabel = new Label();
+ userLabel.Text = "Benutzername";
+ loginStackLayout.Children.Add(userLabel);
+
+ var userEntry = new Entry();
+ userEntry.Text = "Whilem.Brause";
+ loginStackLayout.Children.Add(userEntry);
+
+ var passwordLabel = new Label();
+ passwordLabel.Text = "Passwort";
+ loginStackLayout.Children.Add(passwordLabel);
+
+ var passwordEntry = new Entry();
+ passwordEntry.IsPassword = true;
+ loginStackLayout.Children.Add(passwordEntry);
+
+ var loginButton = new Button();
+ loginButton.Text = "Absenden";
+ loginStackLayout.Children.Add(loginButton);
+
+ border.Content = loginStackLayout;
+ outerStackLayout.Children.Add(border);
+ Content = outerStackLayout;
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/MainPageCsInitializer.cs b/Kap06/MauiDemo/MauiDemo/MainPageCsInitializer.cs
new file mode 100644
index 0000000..8e9e688
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MainPageCsInitializer.cs
@@ -0,0 +1,51 @@
+using Microsoft.Maui.Controls.Shapes;
+namespace MauiDemo;
+public class MainPageCsInitializer : ContentPage
+{
+ public MainPageCsInitializer()
+ {
+ Title = "Login via C#-Initializer";
+ BackgroundColor = Color.FromArgb("#f0f1f7");
+ Content = new StackLayout
+ {
+ Children =
+ {
+ new VerticalStackLayout
+ {
+ Spacing = 25,
+ Padding = 30,
+ Children =
+ {
+ new Label
+ {
+ FontSize = 20,
+ Text="Herzlich Willkommen zur .NET-MAUI-Demo"
+ },
+ new Border
+ {
+ BackgroundColor = Colors.White,
+ Stroke = Colors.White,
+ StrokeShape = new RoundRectangle
+ {
+ CornerRadius = new CornerRadius(10,10,10,10)
+ },
+ Padding= 20,
+ Content = new VerticalStackLayout
+ {
+ Spacing = 15,
+ Children =
+ {
+ new Label { Text= "Benutzername", TextColor = Color.FromArgb("#6d6d6d") },
+ new Entry { Text = "Wilhelm.Brause" },
+ new Label { Text= "Passwort", TextColor = Color.FromArgb("#6d6d6d") },
+ new Entry { IsPassword = true },
+ new Button { Text = "Absenden" }
+ }
+ }
+ }
+ }
+ }
+ }
+ };
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/MauiDemo.csproj b/Kap06/MauiDemo/MauiDemo/MauiDemo.csproj
new file mode 100644
index 0000000..77c633a
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MauiDemo.csproj
@@ -0,0 +1,54 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ MauiDemo
+ true
+ true
+ enable
+
+
+ MauiDemo
+
+
+ com.companyname.mauidemo
+ CE57D239-F38E-4132-A2DF-CC3CF83F8DAB
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/MauiProgram.cs b/Kap06/MauiDemo/MauiDemo/MauiProgram.cs
new file mode 100644
index 0000000..8f16a07
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/MauiProgram.cs
@@ -0,0 +1,19 @@
+namespace MauiDemo
+{
+ public static class MauiProgram
+ {
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Android/AndroidManifest.xml b/Kap06/MauiDemo/MauiDemo/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainActivity.cs b/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..aa31420
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainActivity.cs
@@ -0,0 +1,11 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace MauiDemo
+{
+ [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+ public class MainActivity : MauiAppCompatActivity
+ {
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainApplication.cs b/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..af1a77c
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Android/MainApplication.cs
@@ -0,0 +1,16 @@
+using Android.App;
+using Android.Runtime;
+
+namespace MauiDemo
+{
+ [Application]
+ public class MainApplication : MauiApplication
+ {
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Android/Resources/values/colors.xml b/Kap06/MauiDemo/MauiDemo/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/AppDelegate.cs b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..bb75385
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,10 @@
+using Foundation;
+
+namespace MauiDemo
+{
+ [Register("AppDelegate")]
+ public class AppDelegate : MauiUIApplicationDelegate
+ {
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Info.plist b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Program.cs b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..7a06870
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,16 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace MauiDemo
+{
+ public class Program
+ {
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/Main.cs b/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..f41cfc0
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/Main.cs
@@ -0,0 +1,17 @@
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+using System;
+
+namespace MauiDemo
+{
+ internal class Program : MauiApplication
+ {
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/tizen-manifest.xml b/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..ea3b310
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ appicon.xhigh.png
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..fc8f496
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml.cs b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..10871aa
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace MauiDemo.WinUI
+{
+ ///
+ /// Provides application-specific behavior to supplement the default Application class.
+ ///
+ public partial class App : MauiWinUIApplication
+ {
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Windows/Package.appxmanifest b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/Windows/app.manifest b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..23d8b98
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/iOS/AppDelegate.cs b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..bb75385
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,10 @@
+using Foundation;
+
+namespace MauiDemo
+{
+ [Register("AppDelegate")]
+ public class AppDelegate : MauiUIApplicationDelegate
+ {
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Info.plist b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Program.cs b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..7a06870
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Platforms/iOS/Program.cs
@@ -0,0 +1,16 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace MauiDemo
+{
+ public class Program
+ {
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Properties/launchSettings.json b/Kap06/MauiDemo/MauiDemo/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appicon.svg b/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appiconfg.svg b/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Regular.ttf b/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..534d009
Binary files /dev/null and b/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Semibold.ttf b/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..f333153
Binary files /dev/null and b/Kap06/MauiDemo/MauiDemo/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Raw/AboutAssets.txt b/Kap06/MauiDemo/MauiDemo/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Splash/splash.svg b/Kap06/MauiDemo/MauiDemo/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Styles/Colors.xaml b/Kap06/MauiDemo/MauiDemo/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap06/MauiDemo/MauiDemo/Resources/Styles/Styles.xaml b/Kap06/MauiDemo/MauiDemo/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap06/MauiDemo/MauiDemo/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo.sln b/Kap07/CodeSharingDemo/CodeSharingDemo.sln
new file mode 100644
index 0000000..a84333d
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CodeSharingDemo", "CodeSharingDemo\CodeSharingDemo.csproj", "{4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Release|Any CPU.Build.0 = Release|Any CPU
+ {4958F8AB-AF59-4FF7-8EBB-0E0B926ED8C3}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml
new file mode 100644
index 0000000..7dc2760
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml.cs
new file mode 100644
index 0000000..81e4719
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/App.xaml.cs
@@ -0,0 +1,27 @@
+namespace CodeSharingDemo;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+
+ public static IServiceProvider Services
+ {
+ get
+ {
+#if __ANDROID__
+ return MauiApplication.Current.Services;
+#elif __IOS__
+ return AppDelegate.Current.Services;
+#elif WINDOWS
+ return MauiWinUIApplication.Current.Services;
+#else
+ throw new PlatformNotSupportedException();
+#endif
+ }
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml
new file mode 100644
index 0000000..e27ec3c
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml.cs
new file mode 100644
index 0000000..ca441b8
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace CodeSharingDemo;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/CodeSharingDemo.csproj b/Kap07/CodeSharingDemo/CodeSharingDemo/CodeSharingDemo.csproj
new file mode 100644
index 0000000..bf2aa25
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/CodeSharingDemo.csproj
@@ -0,0 +1,114 @@
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ CodeSharingDemo
+ true
+ true
+ enable
+
+
+ CodeSharingDemo
+
+
+ com.companyname.codesharingdemo
+ 65F3143B-C099-45F9-9EEC-E4A52DAA9A04
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ true
+
+
+ true
+
+
+ false
+
+
+ PraeprozessorDemoPage.xaml
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml
new file mode 100644
index 0000000..95a517a
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml.cs
new file mode 100644
index 0000000..639fb0e
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace CodeSharingDemo;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/MauiProgram.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/MauiProgram.cs
new file mode 100644
index 0000000..3fd313d
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/MauiProgram.cs
@@ -0,0 +1,37 @@
+using CodeSharingDemo.Views;
+
+
+namespace CodeSharingDemo;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+//#if __ANDROID__
+// DependencyService.Register();
+// builder.Services.AddTransient()
+//#elif __MACCATALYST__
+// DependencyService.Register();
+// builder.Services.AddTransient();
+//#elif __IOS__
+// DependencyService.Register();
+// builder.Services.AddTransient();
+//#elif WINDOWS
+// DependencyService.Register();
+// builder.Services.AddTransient();
+//#endif
+ builder.Services.AddTransient();
+ builder.Services.RegisterPlatformServices();
+ DependencyServiceRegistration.RegisterPlatformDependencies();
+ return builder.Build();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidDeviceinfo.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidDeviceinfo.cs
new file mode 100644
index 0000000..1a48abc
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidDeviceinfo.cs
@@ -0,0 +1,9 @@
+using CodeSharingDemo.Services;
+namespace CodeSharingDemo.Droid;
+public class AndroidDeviceInformation : IDeviceInformation
+{
+ public string GetName()
+ {
+ return Android.OS.Build.Device;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidManifest.xml b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DependencyServiceRegistration.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DependencyServiceRegistration.cs
new file mode 100644
index 0000000..5e6a5ef
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DependencyServiceRegistration.cs
@@ -0,0 +1,11 @@
+using CodeSharingDemo.Droid;
+
+namespace CodeSharingDemo;
+
+public static class DependencyServiceRegistration
+{
+ public static void RegisterPlatformDependencies()
+ {
+ DependencyService.Register();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DeviceService.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DeviceService.cs
new file mode 100644
index 0000000..755a3c5
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/DeviceService.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService
+{
+ public partial string GetDeviceName()
+ {
+ return Android.OS.Build.Device;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainActivity.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..a6b423a
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace CodeSharingDemo;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainApplication.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..b13d3ac
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace CodeSharingDemo;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/Resources/values/colors.xml b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/ServiceCollectionRegistrationExtension.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/ServiceCollectionRegistrationExtension.cs
new file mode 100644
index 0000000..e89eda1
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Android/ServiceCollectionRegistrationExtension.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+using CodeSharingDemo.Droid;
+
+namespace CodeSharingDemo
+{
+ public static class ServiceCollectionRegistrationExtension
+ {
+ public static void RegisterPlatformServices(this IServiceCollection services)
+ {
+ services.AddTransient();
+ }
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/AppDelegate.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..3bd1da3
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace CodeSharingDemo;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DependencyServiceRegistration.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DependencyServiceRegistration.cs
new file mode 100644
index 0000000..244845e
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DependencyServiceRegistration.cs
@@ -0,0 +1,11 @@
+using CodeSharingDemo.MacCatalyst;
+
+namespace CodeSharingDemo;
+
+public static class DependencyServiceRegistration
+{
+ public static void RegisterPlatformDependencies()
+ {
+ DependencyService.Register();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DeviceService.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DeviceService.cs
new file mode 100644
index 0000000..b3513c1
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/DeviceService.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService
+{
+ public partial string GetDeviceName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Info.plist b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/MacCatalystDeviceInformation.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/MacCatalystDeviceInformation.cs
new file mode 100644
index 0000000..9379c87
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/MacCatalystDeviceInformation.cs
@@ -0,0 +1,10 @@
+using CodeSharingDemo.Services;
+namespace CodeSharingDemo.MacCatalyst;
+
+public class MacCatalystDeviceInformation : IDeviceInformation
+{
+ public string GetName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Program.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..91ccd0f
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace CodeSharingDemo;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/ServiceCollectionRegistrationExtension.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/ServiceCollectionRegistrationExtension.cs
new file mode 100644
index 0000000..5fc3242
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/MacCatalyst/ServiceCollectionRegistrationExtension.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+using CodeSharingDemo.MacCatalyst;
+
+namespace CodeSharingDemo
+{
+ public static class ServiceCollectionRegistrationExtension
+ {
+ public static void RegisterPlatformServices(this IServiceCollection services)
+ {
+ services.AddTransient();
+ }
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/Main.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..f8af25a
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace CodeSharingDemo;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/tizen-manifest.xml b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..b9b3d7d
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b99d5ff
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..9a1f7b7
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace CodeSharingDemo.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DependencyServiceRegistration.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DependencyServiceRegistration.cs
new file mode 100644
index 0000000..40f223d
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DependencyServiceRegistration.cs
@@ -0,0 +1,11 @@
+using CodeSharingDemo.WinUI;
+
+namespace CodeSharingDemo;
+
+public static class DependencyServiceRegistration
+{
+ public static void RegisterPlatformDependencies()
+ {
+ DependencyService.Register();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DeviceService.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DeviceService.cs
new file mode 100644
index 0000000..50bf995
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/DeviceService.cs
@@ -0,0 +1,10 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService
+{
+ public partial string GetDeviceName()
+ {
+ var deviceInformation = new Windows.Security
+ .ExchangeActiveSyncProvisioning.EasClientDeviceInformation();
+ return deviceInformation.FriendlyName;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/Package.appxmanifest b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/ServiceCollectionRegistrationExtension.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/ServiceCollectionRegistrationExtension.cs
new file mode 100644
index 0000000..61b2994
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/ServiceCollectionRegistrationExtension.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+using CodeSharingDemo.WinUI;
+
+namespace CodeSharingDemo
+{
+ public static class ServiceCollectionRegistrationExtension
+ {
+ public static void RegisterPlatformServices(this IServiceCollection services)
+ {
+ services.AddTransient();
+ }
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/WindowsDeviceInformation.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/WindowsDeviceInformation.cs
new file mode 100644
index 0000000..8ae2522
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/WindowsDeviceInformation.cs
@@ -0,0 +1,15 @@
+using CodeSharingDemo.Services;
+using CodeSharingDemo.WinUI;
+
+[assembly: Dependency(typeof(WindowsDeviceInformation))]
+
+namespace CodeSharingDemo.WinUI;
+public class WindowsDeviceInformation : IDeviceInformation
+{
+ public string GetName()
+ {
+ var deviceInformation = new Windows.Security
+ .ExchangeActiveSyncProvisioning.EasClientDeviceInformation();
+ return deviceInformation.FriendlyName;
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/app.manifest b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..e2e79bd
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/AppDelegate.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..3bd1da3
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace CodeSharingDemo;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DependencyServiceRegistration.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DependencyServiceRegistration.cs
new file mode 100644
index 0000000..9702cd9
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DependencyServiceRegistration.cs
@@ -0,0 +1,11 @@
+using CodeSharingDemo.iOS;
+
+namespace CodeSharingDemo;
+
+public static class DependencyServiceRegistration
+{
+ public static void RegisterPlatformDependencies()
+ {
+ DependencyService.Register();
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DeviceService.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DeviceService.cs
new file mode 100644
index 0000000..b3513c1
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/DeviceService.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService
+{
+ public partial string GetDeviceName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Info.plist b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/IosDeviceInfo.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/IosDeviceInfo.cs
new file mode 100644
index 0000000..16b27fa
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/IosDeviceInfo.cs
@@ -0,0 +1,9 @@
+using CodeSharingDemo.Services;
+namespace CodeSharingDemo.iOS;
+public class IosDeviceInformation: IDeviceInformation
+{
+ public string GetName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Program.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..91ccd0f
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace CodeSharingDemo;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/ServiceCollectionRegistrationExtension.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/ServiceCollectionRegistrationExtension.cs
new file mode 100644
index 0000000..0de23c8
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Platforms/iOS/ServiceCollectionRegistrationExtension.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+using CodeSharingDemo.iOS;
+
+namespace CodeSharingDemo
+{
+ public static class ServiceCollectionRegistrationExtension
+ {
+ public static void RegisterPlatformServices(this IServiceCollection services)
+ {
+ services.AddTransient();
+ }
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Properties/launchSettings.json b/Kap07/CodeSharingDemo/CodeSharingDemo/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appicon.svg b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appiconfg.svg b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Regular.ttf b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Semibold.ttf b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Images/dotnet_bot.svg b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Raw/AboutAssets.txt b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Splash/splash.svg b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Colors.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Styles.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService.cs
new file mode 100644
index 0000000..57cc46d
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService.cs
@@ -0,0 +1,6 @@
+namespace CodeSharingDemo.Services;
+
+public partial class DeviceService
+{
+ public partial string GetDeviceName();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Android.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Android.cs
new file mode 100644
index 0000000..2c69418
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Android.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService2
+{
+ public partial string GetDeviceName()
+ {
+ return Android.OS.Build.Device;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.MacCatalyst.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.MacCatalyst.cs
new file mode 100644
index 0000000..3952eae
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.MacCatalyst.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService2
+{
+ public partial string GetDeviceName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Windows.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Windows.cs
new file mode 100644
index 0000000..0db1aa8
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.Windows.cs
@@ -0,0 +1,10 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService2
+{
+ public partial string GetDeviceName()
+ {
+ var deviceInformation = new Windows.Security
+ .ExchangeActiveSyncProvisioning.EasClientDeviceInformation();
+ return deviceInformation.FriendlyName;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.cs
new file mode 100644
index 0000000..452eb87
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.cs
@@ -0,0 +1,6 @@
+namespace CodeSharingDemo.Services;
+
+public partial class DeviceService2
+{
+ public partial string GetDeviceName();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.iOS.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.iOS.cs
new file mode 100644
index 0000000..3952eae
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/DeviceService2.iOS.cs
@@ -0,0 +1,8 @@
+namespace CodeSharingDemo.Services;
+public partial class DeviceService2
+{
+ public partial string GetDeviceName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Services/IDeviceInfo.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/IDeviceInfo.cs
new file mode 100644
index 0000000..9c00040
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Services/IDeviceInfo.cs
@@ -0,0 +1,6 @@
+namespace CodeSharingDemo.Services;
+
+public interface IDeviceInformation
+{
+ string GetName();
+}
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml
new file mode 100644
index 0000000..4a4a5b6
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml.cs
new file mode 100644
index 0000000..a0f8aca
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyInjectionDemoPage.xaml.cs
@@ -0,0 +1,12 @@
+using CodeSharingDemo.Services;
+
+namespace CodeSharingDemo.Views;
+
+public partial class DependencyInjectionDemoPage : ContentPage
+{
+ public DependencyInjectionDemoPage(IDeviceInformation deviceInfo)
+ {
+ InitializeComponent();
+ DeviceInfoLabel.Text = deviceInfo.GetName();
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml
new file mode 100644
index 0000000..6b21b59
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml.cs
new file mode 100644
index 0000000..24b2382
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/DependencyServiceDemoPage.xaml.cs
@@ -0,0 +1,14 @@
+using CodeSharingDemo.Services;
+
+namespace CodeSharingDemo.Views;
+
+public partial class DependencyServiceDemoPage : ContentPage
+{
+ public DependencyServiceDemoPage()
+ {
+ InitializeComponent();
+ var deviceInfo = DependencyService.Get();
+ DeviceInfoLabel.Text = deviceInfo.GetName();
+
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml
new file mode 100644
index 0000000..bb2477b
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml.cs
new file mode 100644
index 0000000..694ca56
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialDemoPage.xaml.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+
+namespace CodeSharingDemo.Views;
+
+public partial class PartialDemoPage : ContentPage
+{
+ public PartialDemoPage()
+ {
+ InitializeComponent();
+ var deviceService = new DeviceService();
+ DeviceInfoLabel.Text = deviceService.GetDeviceName();
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml
new file mode 100644
index 0000000..240b55b
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml.cs
new file mode 100644
index 0000000..779f1c7
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PartialFileNameBaseDemoPage.xaml.cs
@@ -0,0 +1,13 @@
+using CodeSharingDemo.Services;
+
+namespace CodeSharingDemo.Views;
+
+public partial class PartialFileNameBaseDemoPage : ContentPage
+{
+ public PartialFileNameBaseDemoPage()
+ {
+ InitializeComponent();
+ var deviceService2 = new DeviceService2();
+ DeviceInfoLabel.Text = deviceService2.GetDeviceName();
+ }
+}
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml
new file mode 100644
index 0000000..064e364
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml.cs b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml.cs
new file mode 100644
index 0000000..b578ec0
--- /dev/null
+++ b/Kap07/CodeSharingDemo/CodeSharingDemo/Views/PraeprozessorDemoPage.xaml.cs
@@ -0,0 +1,55 @@
+using static System.Net.Mime.MediaTypeNames;
+
+namespace CodeSharingDemo.Views;
+
+public partial class PraeprozessorDemoPage : ContentPage
+{
+ public PraeprozessorDemoPage()
+ {
+ InitializeComponent();
+ // var text = GetDeviceName();
+ var text = "";
+#if __ANDROID__
+ // Dieser Code wird nur unter Android
+ // in die App hineinkompiliert.
+ text = Android.OS.Build.Device;
+#elif __IOS__
+ // Dieser Code wird nur unter iOS oder macOS
+ // in die App hineinkompiliert.
+ text = UIKit.UIDevice.CurrentDevice.Name;
+
+#elif WINDOWS
+ // Dieser Code wird nur unter Windows
+ // in die App hineinkompiliert
+ var deviceInformation = new Windows.Security
+ .ExchangeActiveSyncProvisioning.EasClientDeviceInformation();
+ text = deviceInformation.FriendlyName;
+#endif
+ DeviceInfoLabel.Text = text;
+
+ }
+
+#if __ANDROID__
+ private string GetDeviceName()
+ {
+ return Android.OS.Build.Device;
+ }
+#endif
+
+#if __IOS__
+ private string GetDeviceName()
+ {
+ return UIKit.UIDevice.CurrentDevice.Name;
+ }
+#endif
+
+#if WINDOWS
+ private string GetDeviceName()
+ {
+ var deviceInformation = new Windows.Security
+ .ExchangeActiveSyncProvisioning.EasClientDeviceInformation();
+ return deviceInformation.FriendlyName;
+ }
+#endif
+
+}
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample.sln b/Kap08/LayoutSample/LayoutSample.sln
new file mode 100644
index 0000000..afeedd5
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LayoutSample", "LayoutSample\LayoutSample.csproj", "{4F445012-DB39-4980-A58E-4A85139FDB3E}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Release|Any CPU.Build.0 = Release|Any CPU
+ {4F445012-DB39-4980-A58E-4A85139FDB3E}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap08/LayoutSample/LayoutSample/App.xaml b/Kap08/LayoutSample/LayoutSample/App.xaml
new file mode 100644
index 0000000..4e01516
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/App.xaml.cs b/Kap08/LayoutSample/LayoutSample/App.xaml.cs
new file mode 100644
index 0000000..17e39d1
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace LayoutSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/AppShell.xaml b/Kap08/LayoutSample/LayoutSample/AppShell.xaml
new file mode 100644
index 0000000..875522f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/AppShell.xaml
@@ -0,0 +1,71 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/AppShell.xaml.cs b/Kap08/LayoutSample/LayoutSample/AppShell.xaml.cs
new file mode 100644
index 0000000..7a93a1f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace LayoutSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/LayoutSample.csproj b/Kap08/LayoutSample/LayoutSample/LayoutSample.csproj
new file mode 100644
index 0000000..82bac6f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/LayoutSample.csproj
@@ -0,0 +1,99 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ LayoutSample
+ true
+ true
+ enable
+
+
+ LayoutSample
+
+
+ com.companyname.layoutsample
+ 44930237-AB53-4FD2-A232-144E52750150
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+ automatic
+
+
+
+ Apple Development: André Krämer (GM64FQT723)
+ VS: WildCard Development
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ HorizontalStackLayoutSamplePage.xaml
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/MainPage.xaml b/Kap08/LayoutSample/LayoutSample/MainPage.xaml
new file mode 100644
index 0000000..c3fd15b
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/MainPage.xaml.cs b/Kap08/LayoutSample/LayoutSample/MainPage.xaml.cs
new file mode 100644
index 0000000..6be6252
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace LayoutSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap08/LayoutSample/LayoutSample/MauiProgram.cs b/Kap08/LayoutSample/LayoutSample/MauiProgram.cs
new file mode 100644
index 0000000..1ad8f3f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace LayoutSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Android/AndroidManifest.xml b/Kap08/LayoutSample/LayoutSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainActivity.cs b/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..17ecec3
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace LayoutSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainApplication.cs b/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..53e6446
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace LayoutSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Android/Resources/values/colors.xml b/Kap08/LayoutSample/LayoutSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..ccccd11
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace LayoutSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Info.plist b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Program.cs b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..7da427e
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace LayoutSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/Main.cs b/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..2b8fcdb
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace LayoutSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/tizen-manifest.xml b/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..dff22e7
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..ae7f7c2
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml.cs b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..3ed6ccc
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace LayoutSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Windows/Package.appxmanifest b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/Windows/app.manifest b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..b89a223
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/iOS/AppDelegate.cs b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..ccccd11
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace LayoutSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Info.plist b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Program.cs b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..7da427e
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace LayoutSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Properties/launchSettings.json b/Kap08/LayoutSample/LayoutSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appicon.svg b/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appiconfg.svg b/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap08/LayoutSample/LayoutSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Images/dotnet_bot.svg b/Kap08/LayoutSample/LayoutSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Raw/AboutAssets.txt b/Kap08/LayoutSample/LayoutSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Splash/splash.svg b/Kap08/LayoutSample/LayoutSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Styles/Colors.xaml b/Kap08/LayoutSample/LayoutSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Resources/Styles/Styles.xaml b/Kap08/LayoutSample/LayoutSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml
new file mode 100644
index 0000000..e703d27
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..ad45335
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/AbsoluteLayoutSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class AbsoluteLayoutSamplePage : ContentPage
+{
+ public AbsoluteLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml
new file mode 100644
index 0000000..c1b69e5
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml.cs
new file mode 100644
index 0000000..d1ef16b
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutJustifyContentSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class FlexLayoutJustifyContentSamplePage : ContentPage
+{
+ public FlexLayoutJustifyContentSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml
new file mode 100644
index 0000000..1cd6863
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..11e09b3
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/FlexLayoutSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class FlexLayoutSamplePage : ContentPage
+{
+ public FlexLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml
new file mode 100644
index 0000000..ed437d1
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml.cs
new file mode 100644
index 0000000..69b0359
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/GridSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class GridSamplePage : ContentPage
+{
+ public GridSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml
new file mode 100644
index 0000000..8ec8945
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml.cs
new file mode 100644
index 0000000..bfcf283
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/GridSpanSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class GridSpanSamplePage : ContentPage
+{
+ public GridSpanSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml
new file mode 100644
index 0000000..c7e051f
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..662a5df
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/HorizontalStackLayoutSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace LayoutSample.Views;
+
+public partial class HorizontalStackLayoutSamplePage : ContentPage
+{
+ public HorizontalStackLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml
new file mode 100644
index 0000000..4f64c34
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..d88ec18
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/NestedStackLayoutSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class NestedStackLayoutSamplePage : ContentPage
+{
+ public NestedStackLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml
new file mode 100644
index 0000000..38fcc81
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml.cs
new file mode 100644
index 0000000..571fbdf
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/ScrollViewSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class ScrollViewSamplePage : ContentPage
+{
+ public ScrollViewSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml
new file mode 100644
index 0000000..9e5aea5
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml.cs
new file mode 100644
index 0000000..4b9bef9
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutLayoutOptionsSamplePage.xaml.cs
@@ -0,0 +1,8 @@
+namespace LayoutSample.Views;
+public partial class StackLayoutLayoutOptionsSamplePage : ContentPage
+{
+ public StackLayoutLayoutOptionsSamplePage()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml
new file mode 100644
index 0000000..6d939da
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..395b689
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/StackLayoutSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace LayoutSample.Views;
+
+public partial class StackLayoutSamplePage : ContentPage
+{
+ public StackLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml b/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml
new file mode 100644
index 0000000..06d74ee
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml.cs b/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml.cs
new file mode 100644
index 0000000..272d237
--- /dev/null
+++ b/Kap08/LayoutSample/LayoutSample/Views/VerticalStackLayoutSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace LayoutSample.Views;
+
+public partial class VerticalStackLayoutSamplePage : ContentPage
+{
+ public VerticalStackLayoutSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..51d42ae
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..2809fbe
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..7029710
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..3125553
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,57 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..17c6256
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..7df20ca
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..dedea2a
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,24 @@
+using ElVegetarianoFurio.Profile;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+
+ return builder.Build();
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap09/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample.sln b/Kap09/ViewsSample/ViewsSample.sln
new file mode 100644
index 0000000..4e27029
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ViewsSample", "ViewsSample\ViewsSample.csproj", "{372E420A-8AAE-429E-AF9C-295D5F90980A}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Release|Any CPU.Build.0 = Release|Any CPU
+ {372E420A-8AAE-429E-AF9C-295D5F90980A}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap09/ViewsSample/ViewsSample/App.xaml b/Kap09/ViewsSample/ViewsSample/App.xaml
new file mode 100644
index 0000000..1cd6ef4
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/App.xaml.cs b/Kap09/ViewsSample/ViewsSample/App.xaml.cs
new file mode 100644
index 0000000..ccf073f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ViewsSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/AppShell.xaml b/Kap09/ViewsSample/ViewsSample/AppShell.xaml
new file mode 100644
index 0000000..3cc595b
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/AppShell.xaml
@@ -0,0 +1,84 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/AppShell.xaml.cs b/Kap09/ViewsSample/ViewsSample/AppShell.xaml.cs
new file mode 100644
index 0000000..71c243b
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/MainPage.xaml b/Kap09/ViewsSample/ViewsSample/MainPage.xaml
new file mode 100644
index 0000000..a36101f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/MainPage.xaml.cs b/Kap09/ViewsSample/ViewsSample/MainPage.xaml.cs
new file mode 100644
index 0000000..f1ad744
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace ViewsSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap09/ViewsSample/ViewsSample/MauiProgram.cs b/Kap09/ViewsSample/ViewsSample/MauiProgram.cs
new file mode 100644
index 0000000..d5a21fe
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace ViewsSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Android/AndroidManifest.xml b/Kap09/ViewsSample/ViewsSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainActivity.cs b/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..af5677f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ViewsSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainApplication.cs b/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..1fa0049
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ViewsSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Android/Resources/values/colors.xml b/Kap09/ViewsSample/ViewsSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..39d798e
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ViewsSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Info.plist b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Program.cs b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1a2117c
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ViewsSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/Main.cs b/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..be4f700
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ViewsSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/tizen-manifest.xml b/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..e0c9b10
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..d50d709
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml.cs b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..1c53c22
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ViewsSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Windows/Package.appxmanifest b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/Windows/app.manifest b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..adca377
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/iOS/AppDelegate.cs b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..39d798e
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ViewsSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Info.plist b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Program.cs b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1a2117c
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ViewsSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Properties/launchSettings.json b/Kap09/ViewsSample/ViewsSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appicon.svg b/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appiconfg.svg b/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap09/ViewsSample/ViewsSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Images/dotnet_bot.svg b/Kap09/ViewsSample/ViewsSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Raw/AboutAssets.txt b/Kap09/ViewsSample/ViewsSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Splash/splash.svg b/Kap09/ViewsSample/ViewsSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Styles/Colors.xaml b/Kap09/ViewsSample/ViewsSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Resources/Styles/Styles.xaml b/Kap09/ViewsSample/ViewsSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap09/ViewsSample/ViewsSample/ViewModels/MvvmSampleViewModel.cs b/Kap09/ViewsSample/ViewsSample/ViewModels/MvvmSampleViewModel.cs
new file mode 100644
index 0000000..1aa83e1
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/ViewModels/MvvmSampleViewModel.cs
@@ -0,0 +1,62 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+using System.Windows.Input;
+
+namespace ViewsSample.ViewModels;
+
+public class MvvmSampleViewModel : INotifyPropertyChanged
+{
+ private string _name;
+ private string _message;
+ public event PropertyChangedEventHandler PropertyChanged;
+
+ public ICommand UpdateMessageCommand { get; set; }
+
+ public MvvmSampleViewModel()
+ {
+ UpdateMessageCommand = new Command(UpdateMessage, CanUpdateMessage);
+ }
+
+ public string Name
+ {
+ get => _name;
+ set
+ {
+ if (_name != value)
+ {
+ _name = value;
+ OnPropertyChanged();
+ (UpdateMessageCommand as Command).ChangeCanExecute();
+ }
+ }
+ }
+
+
+ public string Message
+ {
+ get => _message;
+ set
+ {
+ if (_message != value)
+ {
+ _message = value;
+ OnPropertyChanged();
+ }
+ }
+ }
+
+ private void UpdateMessage()
+ {
+ Message = $"{Name} / {DateTime.Now:g}";
+ }
+
+ private bool CanUpdateMessage()
+ {
+ return !string.IsNullOrEmpty(Name);
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml
new file mode 100644
index 0000000..0f74a93
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml.cs
new file mode 100644
index 0000000..5ec6ab0
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ActivityProgressbarSamplePage.xaml.cs
@@ -0,0 +1,33 @@
+namespace ViewsSample.Views;
+
+public partial class ActivityProgressbarSamplePage : ContentPage
+{
+ public ActivityProgressbarSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void ActivityOn_Clicked(object sender, EventArgs e)
+ {
+ ActivityIndicator1.IsRunning = true;
+ }
+
+ private void ActivityOff_Clicked(object sender, EventArgs e)
+ {
+ ActivityIndicator1.IsRunning = false;
+ }
+
+ private void Button0_Clicked(object sender, EventArgs e)
+ {
+ ProgressBar1.Progress = 0;
+ }
+
+ private void Button33_Clicked(object sender, EventArgs e)
+ {
+ ProgressBar1.Progress = 0.33;
+ }
+ private void Button67_Clicked(object sender, EventArgs e)
+ {
+ ProgressBar1.Progress = 0.67;
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml
new file mode 100644
index 0000000..7661bbf
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml.cs
new file mode 100644
index 0000000..4da8e62
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/BorderSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class BorderSamplePage : ContentPage
+{
+ public BorderSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml
new file mode 100644
index 0000000..387dcd9
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml.cs
new file mode 100644
index 0000000..150a5df
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ButtonSamplePage.xaml.cs
@@ -0,0 +1,14 @@
+namespace ViewsSample.Views;
+
+public partial class ButtonSamplePage : ContentPage
+{
+ public ButtonSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void Button_OnClicked(object sender, EventArgs e)
+ {
+ (sender as Button).Text = "geklickt";
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml
new file mode 100644
index 0000000..54fc07b
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml.cs
new file mode 100644
index 0000000..2f9284f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/CheckBoxSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class CheckBoxSamplePage : ContentPage
+{
+ public CheckBoxSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml
new file mode 100644
index 0000000..bfb4a4a
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml.cs
new file mode 100644
index 0000000..698d0d4
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/DatePickerTimePickerSamplePage.xaml.cs
@@ -0,0 +1,25 @@
+using System.ComponentModel;
+
+namespace ViewsSample.Views;
+
+public partial class DatePickerTimePickerSamplePage : ContentPage
+{
+ public DatePickerTimePickerSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void DatePicker_OnDateSelected(object sender, DateChangedEventArgs e)
+ {
+ ResultDateLabel.Text = e.NewDate.ToShortDateString();
+ }
+
+ private void TimePicker_Changed(object sender, PropertyChangedEventArgs e)
+ {
+ if (e.PropertyName == "Time") // prüfen, ob die Uhrzeit verändert wurde
+ {
+ var timepicker = (TimePicker)sender;
+ ResultTimeLabel.Text = timepicker.Time.ToString("g");
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml
new file mode 100644
index 0000000..1bbd935
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml
@@ -0,0 +1,32 @@
+
+
+
+
+
+
+
+
+ ]]>
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml.cs
new file mode 100644
index 0000000..df6e82a
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/LabelSamplePage.xaml.cs
@@ -0,0 +1,10 @@
+namespace ViewsSample.Views;
+
+public partial class LabelSamplePage : ContentPage
+{
+ public LabelSamplePage()
+ {
+ InitializeComponent();
+ MeinLabel.Text = "Hallo";
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml
new file mode 100644
index 0000000..d2ccdb9
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml.cs
new file mode 100644
index 0000000..2c5291e
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/MvvmSamplePage.xaml.cs
@@ -0,0 +1,12 @@
+using ViewsSample.ViewModels;
+
+namespace ViewsSample.Views;
+
+public partial class MvvmSamplePage : ContentPage
+{
+ public MvvmSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = new MvvmSampleViewModel();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml
new file mode 100644
index 0000000..3f02202
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+ Option 1
+ Option 2
+ Option 3
+ Option 4
+ Option 5
+ Option 6
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml.cs
new file mode 100644
index 0000000..185f5fd
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/PickerSamplePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ViewsSample.Views;
+public partial class PickerSamplePage : ContentPage
+{
+ public PickerSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void Picker_OnSelectedIndexChanged(object sender, EventArgs e)
+ {
+ var picker = (Picker)sender;
+ var index = picker.SelectedIndex;
+
+ if (index != -1)
+ {
+ ResultLabel.Text = picker.Items[index];
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml
new file mode 100644
index 0000000..1a2c9e2
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml.cs
new file mode 100644
index 0000000..73e9f9f
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/RadioButtonSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+namespace ViewsSample.Views;
+public partial class RadioButtonSamplePage : ContentPage
+{
+ public RadioButtonSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void RadioButtonGroup1_OnCheckedChanged(object sender, CheckedChangedEventArgs e)
+ {
+ var value = (sender as RadioButton).Value;
+ Option1ResultLabel.Text = $"Sie haben {value} ausgewählt";
+ }
+
+ private void RadioButtonGroup2_OnCheckedChanged(object sender, CheckedChangedEventArgs e)
+ {
+ var value = (sender as RadioButton).Value;
+ Option2ResultLabel.Text = $"Sie haben {value} ausgewählt";
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml
new file mode 100644
index 0000000..1ed8645
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml.cs
new file mode 100644
index 0000000..b525e76
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ShadowSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class ShadowSamplePage : ContentPage
+{
+ public ShadowSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml
new file mode 100644
index 0000000..e063438
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml.cs
new file mode 100644
index 0000000..19fd771
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/ShapesSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class ShapesSamplePage : ContentPage
+{
+ public ShapesSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml
new file mode 100644
index 0000000..9400620
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml.cs
new file mode 100644
index 0000000..c6378df
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/SwitchSamplePage.xaml.cs
@@ -0,0 +1,33 @@
+namespace ViewsSample.Views;
+
+public partial class SwitchSamplePage : ContentPage
+{
+ public SwitchSamplePage()
+ {
+ InitializeComponent();
+ }
+
+
+ private async void Switch_OnToggled(object sender, ToggledEventArgs e)
+ {
+ try
+ {
+ if (e.Value)
+ {
+ await Flashlight.TurnOnAsync();
+ }
+ else
+ {
+ await Flashlight.TurnOffAsync();
+ }
+ }
+ catch (FeatureNotSupportedException)
+ {
+ await DisplayAlert("Taschenlampe", $"Taschenlampe wird auf diesem Gerät nicht unterstützt. Wert: {e.Value}", "Ok");
+ }
+ catch (PermissionException)
+ {
+ await DisplayAlert("Taschenlampe", $"Berechtigung für Taschenlampe fehlt. Wert: {e.Value}", "Ok");
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml
new file mode 100644
index 0000000..d26dfd2
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml.cs
new file mode 100644
index 0000000..36008a5
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/TextSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class TextSamplePage : ContentPage
+{
+ public TextSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml b/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml
new file mode 100644
index 0000000..c65f7fa
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+ Demo
+
+ Darstellung von inline Html
+ Auch inline Html kann dargestellt werden.
+
+
+ ]]>
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml.cs b/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml.cs
new file mode 100644
index 0000000..64501c0
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/Views/WebViewSamplePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ViewsSample.Views;
+
+public partial class WebViewSamplePage : ContentPage
+{
+ public WebViewSamplePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap09/ViewsSample/ViewsSample/ViewsSample.csproj b/Kap09/ViewsSample/ViewsSample/ViewsSample.csproj
new file mode 100644
index 0000000..f551263
--- /dev/null
+++ b/Kap09/ViewsSample/ViewsSample/ViewsSample.csproj
@@ -0,0 +1,96 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ViewsSample
+ true
+ true
+ enable
+
+
+ ViewsSample
+
+
+ com.companyname.viewssample
+ F140ED0F-A839-44F6-806F-3BD44994A864
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..51d42ae
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..ed744c5
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..7029710
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
new file mode 100644
index 0000000..6632a7c
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
@@ -0,0 +1,13 @@
+namespace ElVegetarianoFurio.Core;
+
+public interface INavigationService
+{
+ Task GoToAsync(string location);
+ Task GoToAsync(string location, bool animate);
+
+ Task GoToAsync(string location, Dictionary paramters);
+
+ Task GoToAsync(string location, bool animate, Dictionary paramters);
+}
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
new file mode 100644
index 0000000..b217d05
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
@@ -0,0 +1,26 @@
+namespace ElVegetarianoFurio.Core;
+
+public class NavigationService : INavigationService
+{
+ public async Task GoToAsync(string location)
+ {
+ await Shell.Current.GoToAsync(location);
+ }
+
+ public async Task GoToAsync(string location, bool animate)
+ {
+ await Shell.Current.GoToAsync(location, animate);
+ }
+
+ public async Task GoToAsync(string location, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, paramters);
+ }
+
+ public async Task GoToAsync(string location, bool animate, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, animate, paramters);
+ }
+}
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..3125553
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,57 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..17c6256
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..7df20ca
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..fabc19e
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,25 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Profile;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ return builder.Build();
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap10/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample.sln b/Kap10/FlyoutSample/FlyoutSample.sln
new file mode 100644
index 0000000..37091ae
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FlyoutSample", "FlyoutSample\FlyoutSample.csproj", "{C7450741-91DC-43E0-94F2-CA62E37A34B3}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Release|Any CPU.Build.0 = Release|Any CPU
+ {C7450741-91DC-43E0-94F2-CA62E37A34B3}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap10/FlyoutSample/FlyoutSample/App.xaml b/Kap10/FlyoutSample/FlyoutSample/App.xaml
new file mode 100644
index 0000000..5c2bb54
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/App.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/App.xaml.cs
new file mode 100644
index 0000000..bccd887
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace FlyoutSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new MainPage();
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/FlyoutSample.csproj b/Kap10/FlyoutSample/FlyoutSample/FlyoutSample.csproj
new file mode 100644
index 0000000..9e4bb47
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/FlyoutSample.csproj
@@ -0,0 +1,68 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ FlyoutSample
+ true
+ true
+ enable
+
+
+ FlyoutSample
+
+
+ com.companyname.flyoutsample
+ 74C16B29-03DF-4310-AC0A-E9CE15C2F21D
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml b/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml
new file mode 100644
index 0000000..772ad60
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml.cs
new file mode 100644
index 0000000..42a1713
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/HomePage.xaml.cs
@@ -0,0 +1,9 @@
+namespace FlyoutSample;
+
+public partial class HomePage : ContentPage
+{
+ public HomePage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml b/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml
new file mode 100644
index 0000000..acd485f
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml.cs
new file mode 100644
index 0000000..9736d11
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace FlyoutSample;
+
+public partial class MainPage : FlyoutPage
+{
+ public MainPage()
+ {
+ InitializeComponent();
+ FlyoutPage.MenuItemsCollectionView.SelectionChanged += OnSelectionChanged;
+ }
+
+ private void OnSelectionChanged(object sender, SelectionChangedEventArgs e)
+ {
+ // prüfen, ob der ausgewählte Eintrag vom korrekten Typ ist
+ if (e.CurrentSelection.FirstOrDefault() is MainPageFlyoutMenuItem item)
+ {
+ // Detailseite erzeugen und die Navigation durchführen
+ Detail = new NavigationPage((Page)Activator.CreateInstance(item.TargetType));
+
+ // Flyout wieder einklappen
+ IsPresented = false;
+ }
+ }
+}
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml
new file mode 100644
index 0000000..db245ce
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml.cs
new file mode 100644
index 0000000..9d9c78e
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyout.xaml.cs
@@ -0,0 +1,28 @@
+using System.Collections.ObjectModel;
+
+namespace FlyoutSample;
+
+public partial class MainPageFlyout : ContentPage
+{
+ public ObservableCollection MenuItems { get; }
+ public MainPageFlyout()
+ {
+ InitializeComponent();
+ MenuItems = new ObservableCollection(new[]
+ {
+ new MainPageFlyoutMenuItem
+ {
+ Title = "Startseite",
+ TargetType = typeof(HomePage),
+ Image = "home.png"
+ },
+ new MainPageFlyoutMenuItem
+ {
+ Title = "Einstellungen",
+ TargetType = typeof(SettingsPage),
+ Image = "settings.png"
+ },
+ });
+ BindingContext = this;
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/MainPageFlyoutItem.cs b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyoutItem.cs
new file mode 100644
index 0000000..58e324e
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MainPageFlyoutItem.cs
@@ -0,0 +1,8 @@
+namespace FlyoutSample;
+
+public class MainPageFlyoutMenuItem
+{
+ public string Title { get; set; }
+ public ImageSource Image { get; set; }
+ public Type TargetType { get; set; }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/MauiProgram.cs b/Kap10/FlyoutSample/FlyoutSample/MauiProgram.cs
new file mode 100644
index 0000000..b5431c0
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace FlyoutSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/AndroidManifest.xml b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainActivity.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..1308c43
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace FlyoutSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainApplication.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..172f075
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace FlyoutSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/Resources/values/colors.xml b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..d254c39
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace FlyoutSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Info.plist b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Program.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..4e04429
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace FlyoutSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/Main.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..ab44246
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace FlyoutSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/tizen-manifest.xml b/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..16426e9
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..29245ab
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..114e671
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace FlyoutSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/Package.appxmanifest b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/app.manifest b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..9073cd3
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/AppDelegate.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..d254c39
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace FlyoutSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Info.plist b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Program.cs b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..4e04429
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace FlyoutSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/FlyoutSample/FlyoutSample/Properties/launchSettings.json b/Kap10/FlyoutSample/FlyoutSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appicon.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appiconfg.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap10/FlyoutSample/FlyoutSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Images/dotnet_bot.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Images/home.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/home.svg
new file mode 100644
index 0000000..40771f9
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/home.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Images/menu.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/menu.svg
new file mode 100644
index 0000000..a090c0e
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/menu.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Images/settings.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/settings.svg
new file mode 100644
index 0000000..9a093ef
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Images/settings.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Raw/AboutAssets.txt b/Kap10/FlyoutSample/FlyoutSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Splash/splash.svg b/Kap10/FlyoutSample/FlyoutSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Colors.xaml b/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Styles.xaml b/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml b/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml
new file mode 100644
index 0000000..9ee660e
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml.cs b/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml.cs
new file mode 100644
index 0000000..cb52984
--- /dev/null
+++ b/Kap10/FlyoutSample/FlyoutSample/SettingsPage.xaml.cs
@@ -0,0 +1,9 @@
+namespace FlyoutSample;
+
+public partial class SettingsPage : ContentPage
+{
+ public SettingsPage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample.sln b/Kap10/HierarchicalSample/HierarchicalSample.sln
new file mode 100644
index 0000000..f07f57b
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HierarchicalSample", "HierarchicalSample\HierarchicalSample.csproj", "{389878B7-1200-4B59-AF4A-0A624742422D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Release|Any CPU.Build.0 = Release|Any CPU
+ {389878B7-1200-4B59-AF4A-0A624742422D}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/App.xaml b/Kap10/HierarchicalSample/HierarchicalSample/App.xaml
new file mode 100644
index 0000000..57ed71d
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/App.xaml.cs b/Kap10/HierarchicalSample/HierarchicalSample/App.xaml.cs
new file mode 100644
index 0000000..a4812dd
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace HierarchicalSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new NavigationPage(new Page1());
+ }
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/HierarchicalSample.csproj b/Kap10/HierarchicalSample/HierarchicalSample/HierarchicalSample.csproj
new file mode 100644
index 0000000..35d77fe
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/HierarchicalSample.csproj
@@ -0,0 +1,60 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ HierarchicalSample
+ true
+ true
+ enable
+
+
+ HierarchicalSample
+
+
+ com.companyname.hierarchicalsample
+ 1E6ED3F3-0ECB-4857-A701-737DE0058D46
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/MauiProgram.cs b/Kap10/HierarchicalSample/HierarchicalSample/MauiProgram.cs
new file mode 100644
index 0000000..d716e41
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace HierarchicalSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml b/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml
new file mode 100644
index 0000000..4f5356b
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml.cs b/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml.cs
new file mode 100644
index 0000000..33241ac
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Page1.xaml.cs
@@ -0,0 +1,14 @@
+namespace HierarchicalSample;
+
+public partial class Page1 : ContentPage
+{
+ public Page1()
+ {
+ InitializeComponent();
+ }
+
+ private async void Button_Clicked(object sender, EventArgs e)
+ {
+ await Navigation.PushAsync(new Page2());
+ }
+}
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml b/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml
new file mode 100644
index 0000000..256c178
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml.cs b/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml.cs
new file mode 100644
index 0000000..bb5772d
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Page2.xaml.cs
@@ -0,0 +1,9 @@
+namespace HierarchicalSample;
+
+public partial class Page2 : ContentPage
+{
+ public Page2()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/AndroidManifest.xml b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainActivity.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..3b72e4b
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace HierarchicalSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainApplication.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..0960fe1
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace HierarchicalSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/Resources/values/colors.xml b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..45d99e0
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace HierarchicalSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Info.plist b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Program.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..d081a99
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace HierarchicalSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/Main.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..1cc5952
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace HierarchicalSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/tizen-manifest.xml b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..1a829c6
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..0f4f504
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..7848804
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace HierarchicalSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/Package.appxmanifest b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/app.manifest b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..803dd1c
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/AppDelegate.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..45d99e0
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace HierarchicalSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Info.plist b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Program.cs b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..d081a99
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace HierarchicalSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Properties/launchSettings.json b/Kap10/HierarchicalSample/HierarchicalSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appicon.svg b/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appiconfg.svg b/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Images/dotnet_bot.svg b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Raw/AboutAssets.txt b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Splash/splash.svg b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Colors.xaml b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Styles.xaml b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap10/HierarchicalSample/HierarchicalSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample.sln b/Kap10/ShellSample/ShellSample.sln
new file mode 100644
index 0000000..dced082
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ShellSample", "ShellSample\ShellSample.csproj", "{6FCFF28B-C621-41F8-A1F4-0F784DBDF227}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Release|Any CPU.Build.0 = Release|Any CPU
+ {6FCFF28B-C621-41F8-A1F4-0F784DBDF227}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap10/ShellSample/ShellSample/App.xaml b/Kap10/ShellSample/ShellSample/App.xaml
new file mode 100644
index 0000000..1e9987d
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/App.xaml.cs b/Kap10/ShellSample/ShellSample/App.xaml.cs
new file mode 100644
index 0000000..40f3687
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ShellSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/AppShell.xaml b/Kap10/ShellSample/ShellSample/AppShell.xaml
new file mode 100644
index 0000000..0377ecf
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/AppShell.xaml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/AppShell.xaml.cs b/Kap10/ShellSample/ShellSample/AppShell.xaml.cs
new file mode 100644
index 0000000..93523b8
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/AppShell.xaml.cs
@@ -0,0 +1,16 @@
+namespace ShellSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(NavigationDemoTargetPage), typeof(NavigationDemoTargetPage));
+ }
+
+ private async void MenuItem_Clicked(object sender, EventArgs e)
+ {
+ await DisplayAlert("Versionsinfo", "1.0.0", "Ok");
+ FlyoutIsPresented = false; // Flyout wieder schließen
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/MainPage.xaml b/Kap10/ShellSample/ShellSample/MainPage.xaml
new file mode 100644
index 0000000..39c2a14
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/MainPage.xaml.cs b/Kap10/ShellSample/ShellSample/MainPage.xaml.cs
new file mode 100644
index 0000000..c18b07d
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace ShellSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap10/ShellSample/ShellSample/MauiProgram.cs b/Kap10/ShellSample/ShellSample/MauiProgram.cs
new file mode 100644
index 0000000..74fe714
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace ShellSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml b/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml
new file mode 100644
index 0000000..05b40b1
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml.cs b/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml.cs
new file mode 100644
index 0000000..504eb65
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/NavigationDemoSourcePage.xaml.cs
@@ -0,0 +1,21 @@
+namespace ShellSample;
+
+public partial class NavigationDemoSourcePage : ContentPage
+{
+ public NavigationDemoSourcePage()
+ {
+ InitializeComponent();
+ }
+
+ private async void Button_Clicked(object sender, EventArgs e)
+ {
+ var navigationParameters = new Dictionary
+ {
+ {"FirstName", FirstNameEntry.Text },
+ {"LastName", LastNameEntry.Text },
+ {"Age", AgeEntry.Text },
+ };
+ await Shell.Current.GoToAsync($"{nameof(NavigationDemoTargetPage)}", navigationParameters);
+ //await Shell.Current.GoToAsync($"{nameof(NavigationDemoTargetPage)}?FirstName={FirstNameEntry.Text}&LastName={LastNameEntry.Text}&Age={AgeEntry.Text}");
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml b/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml
new file mode 100644
index 0000000..f0570d7
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml.cs b/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml.cs
new file mode 100644
index 0000000..4990f86
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/NavigationDemoTargetPage.xaml.cs
@@ -0,0 +1,37 @@
+namespace ShellSample;
+
+[QueryProperty(nameof(FirstName), nameof(FirstName))]
+[QueryProperty(nameof(LastName), nameof(LastName))]
+[QueryProperty(nameof(Age), nameof(Age))]
+public partial class NavigationDemoTargetPage : ContentPage //, IQueryAttributable
+{
+
+ public NavigationDemoTargetPage()
+ {
+ InitializeComponent();
+ }
+
+ public string FirstName { get; set; }
+
+ public string LastName { get; set; }
+
+ public int Age { get; set; }
+
+ // Alteranativer Weg, falls IQueryAttributable implementiert wird
+ //public void ApplyQueryAttributes(IDictionary query)
+ //{
+ // FirstName = HttpUtility.UrlDecode(query["FirstName"].ToString());
+ // LastName = HttpUtility.UrlDecode(query["LastName"].ToString());
+ // if(int.TryParse(HttpUtility.UrlDecode(query["Age"].ToString()), out int age))
+ // {
+ // Age = age;
+ // }
+ // MessageLabel.Text = $"Ihr Name lautet {FirstName} {LastName}. Sie sind {Age} Jahre alt.";
+ //}
+
+ protected override void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ MessageLabel.Text = $"Ihr Name lautet {FirstName} {LastName}. Sie sind {Age} Jahre alt.";
+ base.OnNavigatedTo(args);
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Android/AndroidManifest.xml b/Kap10/ShellSample/ShellSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Android/MainActivity.cs b/Kap10/ShellSample/ShellSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..4634415
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ShellSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Android/MainApplication.cs b/Kap10/ShellSample/ShellSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..6aaa641
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ShellSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Android/Resources/values/colors.xml b/Kap10/ShellSample/ShellSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..0f7e1a7
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ShellSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Info.plist b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Program.cs b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..49b72a3
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ShellSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Tizen/Main.cs b/Kap10/ShellSample/ShellSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..b0ade54
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ShellSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Tizen/tizen-manifest.xml b/Kap10/ShellSample/ShellSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..a6d50d7
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml b/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..4322fea
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml.cs b/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..d1db16b
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ShellSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Windows/Package.appxmanifest b/Kap10/ShellSample/ShellSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/Windows/app.manifest b/Kap10/ShellSample/ShellSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..9f1f1c3
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/iOS/AppDelegate.cs b/Kap10/ShellSample/ShellSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..0f7e1a7
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ShellSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/ShellSample/ShellSample/Platforms/iOS/Info.plist b/Kap10/ShellSample/ShellSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/ShellSample/ShellSample/Platforms/iOS/Program.cs b/Kap10/ShellSample/ShellSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..49b72a3
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ShellSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/ShellSample/ShellSample/Properties/launchSettings.json b/Kap10/ShellSample/ShellSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/AppIcon/appicon.svg b/Kap10/ShellSample/ShellSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/AppIcon/appiconfg.svg b/Kap10/ShellSample/ShellSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap10/ShellSample/ShellSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap10/ShellSample/ShellSample/Resources/Images/dotnet_bot.svg b/Kap10/ShellSample/ShellSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap10/ShellSample/ShellSample/Resources/Images/home.svg b/Kap10/ShellSample/ShellSample/Resources/Images/home.svg
new file mode 100644
index 0000000..40771f9
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Images/home.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Images/info.svg b/Kap10/ShellSample/ShellSample/Resources/Images/info.svg
new file mode 100644
index 0000000..4023e87
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Images/info.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Images/navigation.svg b/Kap10/ShellSample/ShellSample/Resources/Images/navigation.svg
new file mode 100644
index 0000000..f91bd48
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Images/navigation.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Images/settings.svg b/Kap10/ShellSample/ShellSample/Resources/Images/settings.svg
new file mode 100644
index 0000000..9a093ef
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Images/settings.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Raw/AboutAssets.txt b/Kap10/ShellSample/ShellSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap10/ShellSample/ShellSample/Resources/Splash/splash.svg b/Kap10/ShellSample/ShellSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Styles/Colors.xaml b/Kap10/ShellSample/ShellSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/Resources/Styles/Styles.xaml b/Kap10/ShellSample/ShellSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/ShellSample/ShellSample/SettingsPage.xaml b/Kap10/ShellSample/ShellSample/SettingsPage.xaml
new file mode 100644
index 0000000..113e6a9
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/SettingsPage.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/SettingsPage.xaml.cs b/Kap10/ShellSample/ShellSample/SettingsPage.xaml.cs
new file mode 100644
index 0000000..eab037a
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/SettingsPage.xaml.cs
@@ -0,0 +1,9 @@
+namespace ShellSample;
+
+public partial class SettingsPage : ContentPage
+{
+ public SettingsPage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/ShellSample/ShellSample/ShellSample.csproj b/Kap10/ShellSample/ShellSample/ShellSample.csproj
new file mode 100644
index 0000000..6cccb52
--- /dev/null
+++ b/Kap10/ShellSample/ShellSample/ShellSample.csproj
@@ -0,0 +1,70 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ShellSample
+ true
+ true
+ enable
+
+
+ ShellSample
+
+
+ com.companyname.shellsample
+ D6FB448C-AE91-4144-8223-F3B2E498B4F3
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample.sln b/Kap10/TabsSample/TabsSample.sln
new file mode 100644
index 0000000..08c1d44
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TabsSample", "TabsSample\TabsSample.csproj", "{C60D6720-104B-457A-A8D3-2C707EEEAC00}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Release|Any CPU.Build.0 = Release|Any CPU
+ {C60D6720-104B-457A-A8D3-2C707EEEAC00}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap10/TabsSample/TabsSample/App.xaml b/Kap10/TabsSample/TabsSample/App.xaml
new file mode 100644
index 0000000..3e30c5c
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/App.xaml.cs b/Kap10/TabsSample/TabsSample/App.xaml.cs
new file mode 100644
index 0000000..342506e
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace TabsSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new MainPage();
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/AppShell.xaml b/Kap10/TabsSample/TabsSample/AppShell.xaml
new file mode 100644
index 0000000..51fce7b
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/AppShell.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/AppShell.xaml.cs b/Kap10/TabsSample/TabsSample/AppShell.xaml.cs
new file mode 100644
index 0000000..1c7dd4c
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace TabsSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/MainPage.xaml b/Kap10/TabsSample/TabsSample/MainPage.xaml
new file mode 100644
index 0000000..0cbcc0a
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/MainPage.xaml
@@ -0,0 +1,8 @@
+
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/MainPage.xaml.cs b/Kap10/TabsSample/TabsSample/MainPage.xaml.cs
new file mode 100644
index 0000000..014ea48
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/MainPage.xaml.cs
@@ -0,0 +1,10 @@
+namespace TabsSample;
+
+public partial class MainPage : TabbedPage
+{
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+}
+
diff --git a/Kap10/TabsSample/TabsSample/MauiProgram.cs b/Kap10/TabsSample/TabsSample/MauiProgram.cs
new file mode 100644
index 0000000..1be82dd
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace TabsSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/Page1.xaml b/Kap10/TabsSample/TabsSample/Page1.xaml
new file mode 100644
index 0000000..f3d6508
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Page1.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Page1.xaml.cs b/Kap10/TabsSample/TabsSample/Page1.xaml.cs
new file mode 100644
index 0000000..06d3691
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Page1.xaml.cs
@@ -0,0 +1,9 @@
+namespace TabsSample;
+
+public partial class Page1 : ContentPage
+{
+ public Page1()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Page2.xaml b/Kap10/TabsSample/TabsSample/Page2.xaml
new file mode 100644
index 0000000..ddd0897
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Page2.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Page2.xaml.cs b/Kap10/TabsSample/TabsSample/Page2.xaml.cs
new file mode 100644
index 0000000..b950769
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Page2.xaml.cs
@@ -0,0 +1,9 @@
+namespace TabsSample;
+
+public partial class Page2 : ContentPage
+{
+ public Page2()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Android/AndroidManifest.xml b/Kap10/TabsSample/TabsSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Android/MainActivity.cs b/Kap10/TabsSample/TabsSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..67dcd25
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace TabsSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Android/MainApplication.cs b/Kap10/TabsSample/TabsSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..dab5ddc
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace TabsSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Android/Resources/values/colors.xml b/Kap10/TabsSample/TabsSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..628d85a
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace TabsSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Info.plist b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Program.cs b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..d67b218
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace TabsSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Tizen/Main.cs b/Kap10/TabsSample/TabsSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..1648329
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace TabsSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Tizen/tizen-manifest.xml b/Kap10/TabsSample/TabsSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..674a968
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml b/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..4ed634e
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml.cs b/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..9a75f5e
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace TabsSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Windows/Package.appxmanifest b/Kap10/TabsSample/TabsSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/Windows/app.manifest b/Kap10/TabsSample/TabsSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..d0a718c
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/iOS/AppDelegate.cs b/Kap10/TabsSample/TabsSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..628d85a
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace TabsSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap10/TabsSample/TabsSample/Platforms/iOS/Info.plist b/Kap10/TabsSample/TabsSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap10/TabsSample/TabsSample/Platforms/iOS/Program.cs b/Kap10/TabsSample/TabsSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..d67b218
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace TabsSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap10/TabsSample/TabsSample/Properties/launchSettings.json b/Kap10/TabsSample/TabsSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/AppIcon/appicon.svg b/Kap10/TabsSample/TabsSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/AppIcon/appiconfg.svg b/Kap10/TabsSample/TabsSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap10/TabsSample/TabsSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap10/TabsSample/TabsSample/Resources/Images/dotnet_bot.svg b/Kap10/TabsSample/TabsSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap10/TabsSample/TabsSample/Resources/Images/home.svg b/Kap10/TabsSample/TabsSample/Resources/Images/home.svg
new file mode 100644
index 0000000..40771f9
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Images/home.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/Images/settings.svg b/Kap10/TabsSample/TabsSample/Resources/Images/settings.svg
new file mode 100644
index 0000000..9a093ef
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Images/settings.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/Raw/AboutAssets.txt b/Kap10/TabsSample/TabsSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap10/TabsSample/TabsSample/Resources/Splash/splash.svg b/Kap10/TabsSample/TabsSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/Styles/Colors.xaml b/Kap10/TabsSample/TabsSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap10/TabsSample/TabsSample/Resources/Styles/Styles.xaml b/Kap10/TabsSample/TabsSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap10/TabsSample/TabsSample/TabsSample.csproj b/Kap10/TabsSample/TabsSample/TabsSample.csproj
new file mode 100644
index 0000000..7d72272
--- /dev/null
+++ b/Kap10/TabsSample/TabsSample/TabsSample.csproj
@@ -0,0 +1,65 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ TabsSample
+ true
+ true
+ enable
+
+
+ TabsSample
+
+
+ com.companyname.tabssample
+ CEB421DD-C0D7-41D4-B3F5-3B1824A00A26
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples.sln b/Kap11/CollectionViewSamples/CollectionViewSamples.sln
new file mode 100644
index 0000000..adb6364
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CollectionViewSamples", "CollectionViewSamples\CollectionViewSamples.csproj", "{2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Release|Any CPU.Build.0 = Release|Any CPU
+ {2CC1CF36-6FA3-4EB2-A244-8CBD27932C9D}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml
new file mode 100644
index 0000000..9ce3f56
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml.cs
new file mode 100644
index 0000000..cc6d7a9
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace CollectionViewSamples;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml
new file mode 100644
index 0000000..c7d896b
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml
@@ -0,0 +1,36 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml.cs
new file mode 100644
index 0000000..126207e
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace CollectionViewSamples;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/CollectionViewSamples.csproj b/Kap11/CollectionViewSamples/CollectionViewSamples/CollectionViewSamples.csproj
new file mode 100644
index 0000000..f9e66c5
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/CollectionViewSamples.csproj
@@ -0,0 +1,69 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ CollectionViewSamples
+ true
+ true
+ enable
+
+
+ CollectionViewSamples
+
+
+ com.companyname.collectionviewsamples
+ C9130FC0-4EDE-483A-9D8B-25154F4E50BB
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml
new file mode 100644
index 0000000..620cec9
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml.cs
new file mode 100644
index 0000000..7005869
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace CollectionViewSamples;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/MauiProgram.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/MauiProgram.cs
new file mode 100644
index 0000000..7418de1
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/MauiProgram.cs
@@ -0,0 +1,20 @@
+using CollectionViewSamples.Services;
+
+namespace CollectionViewSamples;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+ DependencyService.Register();
+ return builder.Build();
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Models/Item.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Models/Item.cs
new file mode 100644
index 0000000..d0538bd
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Models/Item.cs
@@ -0,0 +1,9 @@
+namespace CollectionViewSamples.Models
+{
+ public class Item
+ {
+ public string Id { get; set; }
+ public string Text { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Models/ItemGroup.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Models/ItemGroup.cs
new file mode 100644
index 0000000..501311b
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Models/ItemGroup.cs
@@ -0,0 +1,14 @@
+using System.Collections.Generic;
+
+namespace CollectionViewSamples.Models
+{
+ public class ItemGroup: List-
+ {
+ public string Name { get; private set; }
+
+ public ItemGroup(string name, List
- items): base(items)
+ {
+ Name = name;
+ }
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/AndroidManifest.xml b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainActivity.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..0ceba12
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace CollectionViewSamples;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainApplication.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..f6dc789
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace CollectionViewSamples;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/Resources/values/colors.xml b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/AppDelegate.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..53e8cdb
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace CollectionViewSamples;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Info.plist b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Program.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..80a782f
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace CollectionViewSamples;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/Main.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..90e10b7
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace CollectionViewSamples;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/tizen-manifest.xml b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..a8a62ba
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b62e88e
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..e126182
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace CollectionViewSamples.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/Package.appxmanifest b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/app.manifest b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..d1e49ef
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/AppDelegate.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..53e8cdb
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace CollectionViewSamples;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Info.plist b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Program.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..80a782f
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace CollectionViewSamples;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Properties/launchSettings.json b/Kap11/CollectionViewSamples/CollectionViewSamples/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appicon.svg b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appiconfg.svg b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Regular.ttf b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Semibold.ttf b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Images/dotnet_bot.svg b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Raw/AboutAssets.txt b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Splash/splash.svg b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Colors.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Styles.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Services/IDataStore.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Services/IDataStore.cs
new file mode 100644
index 0000000..6433bcc
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Services/IDataStore.cs
@@ -0,0 +1,14 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+
+namespace CollectionViewSamples.Services
+{
+ public interface IDataStore
+ {
+ Task AddItemAsync(T item);
+ Task UpdateItemAsync(T item);
+ Task DeleteItemAsync(string id);
+ Task GetItemAsync(string id);
+ Task> GetItemsAsync(bool forceRefresh = false);
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Services/MockDataStore.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Services/MockDataStore.cs
new file mode 100644
index 0000000..e1c8236
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Services/MockDataStore.cs
@@ -0,0 +1,60 @@
+using CollectionViewSamples.Models;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Threading.Tasks;
+
+namespace CollectionViewSamples.Services
+{
+ public class MockDataStore : IDataStore
-
+ {
+ readonly List
- items;
+
+ public MockDataStore()
+ {
+ items = new List
- ()
+ {
+ new Item { Id = Guid.NewGuid().ToString(), Text = "First item", Description="This is an item description." },
+ new Item { Id = Guid.NewGuid().ToString(), Text = "Second item", Description="This is an item description." },
+ new Item { Id = Guid.NewGuid().ToString(), Text = "Third item", Description="This is an item description." },
+ new Item { Id = Guid.NewGuid().ToString(), Text = "Fourth item", Description="This is an item description." },
+ new Item { Id = Guid.NewGuid().ToString(), Text = "Fifth item", Description="This is an item description." },
+ new Item { Id = Guid.NewGuid().ToString(), Text = "Sixth item", Description="This is an item description." }
+ };
+ }
+
+ public async Task AddItemAsync(Item item)
+ {
+ items.Add(item);
+
+ return await Task.FromResult(true);
+ }
+
+ public async Task UpdateItemAsync(Item item)
+ {
+ var oldItem = items.Where((Item arg) => arg.Id == item.Id).FirstOrDefault();
+ items.Remove(oldItem);
+ items.Add(item);
+
+ return await Task.FromResult(true);
+ }
+
+ public async Task DeleteItemAsync(string id)
+ {
+ var oldItem = items.Where((Item arg) => arg.Id == id).FirstOrDefault();
+ items.Remove(oldItem);
+
+ return await Task.FromResult(true);
+ }
+
+ public async Task
- GetItemAsync(string id)
+ {
+ return await Task.FromResult(items.FirstOrDefault(s => s.Id == id));
+ }
+
+ public async Task> GetItemsAsync(bool forceRefresh = false)
+ {
+ return await Task.FromResult(items);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/BaseViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/BaseViewModel.cs
new file mode 100644
index 0000000..3bc4086
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/BaseViewModel.cs
@@ -0,0 +1,76 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+using System.Threading.Tasks;
+using CollectionViewSamples.Services;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public abstract class BaseViewModel : INotifyPropertyChanged
+ {
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+ public IDataStore DataStore => DependencyService.Get>();
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+ }
+}
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/FirstSampleViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/FirstSampleViewModel.cs
new file mode 100644
index 0000000..d0a2b2b
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/FirstSampleViewModel.cs
@@ -0,0 +1,45 @@
+using CollectionViewSamples.Models;
+using System.Collections.ObjectModel;
+using System.Threading.Tasks;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public class FirstSampleViewModel : BaseViewModel
-
+ {
+
+ public ObservableCollection
- Items { get; }
+ public Command LoadItemsCommand { get; }
+ public FirstSampleViewModel()
+ {
+ Title = "Ein einfaches Beispiel";
+ Items = new ObservableCollection
- ();
+ LoadItemsCommand = new Command(async () => await ExecuteLoadItemsCommand());
+ }
+
+ async Task ExecuteLoadItemsCommand()
+ {
+ IsBusy = true;
+
+ try
+ {
+ Items.Clear();
+ var items = await DataStore.GetItemsAsync(true);
+ foreach (var item in items)
+ {
+ Items.Add(item);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ public override async Task Initialize()
+ {
+ await ExecuteLoadItemsCommand();
+ await base.Initialize();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/GroupSampleViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/GroupSampleViewModel.cs
new file mode 100644
index 0000000..6b66d58
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/GroupSampleViewModel.cs
@@ -0,0 +1,54 @@
+using CollectionViewSamples.Models;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.Linq;
+using System.Threading.Tasks;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public class GroupSampleViewModel : BaseViewModel
-
+ {
+
+ public ObservableCollection Items { get; }
+ public Command LoadItemsCommand { get; }
+ public GroupSampleViewModel()
+ {
+ Title = "Gruppierte Einträge";
+ Items = new ObservableCollection();
+ LoadItemsCommand = new Command(async () => await ExecuteLoadItemsCommand());
+ }
+
+ async Task ExecuteLoadItemsCommand()
+ {
+ IsBusy = true;
+
+ try
+ {
+ Items.Clear();
+ var items = await DataStore.GetItemsAsync(true);
+
+ var group = new List
+ {
+ new ItemGroup("Group 1", items.Take(3).ToList()),
+ new ItemGroup("Group 2", items.Skip(3).Take(3).ToList())
+ };
+
+ foreach (var item in group)
+ {
+ Items.Add(item);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ public override async Task Initialize()
+ {
+ await ExecuteLoadItemsCommand();
+ await base.Initialize();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/MenuSampleViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/MenuSampleViewModel.cs
new file mode 100644
index 0000000..2858d6a
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/MenuSampleViewModel.cs
@@ -0,0 +1,59 @@
+using CollectionViewSamples.Models;
+using System;
+using System.Collections.ObjectModel;
+using System.Threading.Tasks;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public class MenuSampleViewModel : BaseViewModel
-
+ {
+ public ObservableCollection
- Items { get; }
+ public Command LoadItemsCommand { get; }
+ public Command
- DeleteItemCommand { get; }
+
+ public MenuSampleViewModel()
+ {
+ Title = "Kontextmenüs";
+ Items = new ObservableCollection
- ();
+ LoadItemsCommand = new Command(async () => await ExecuteLoadItemsCommand());
+ DeleteItemCommand = new Command
- (OnItemDeleted);
+ }
+
+ async Task ExecuteLoadItemsCommand()
+ {
+ IsBusy = true;
+ try
+ {
+ Items.Clear();
+ var items = await DataStore.GetItemsAsync(true);
+ foreach (var item in items)
+ {
+ Items.Add(item);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ public override async Task Initialize()
+ {
+ await ExecuteLoadItemsCommand();
+ await base.Initialize();
+ }
+
+
+ async void OnItemDeleted(Item item)
+ {
+ if (item != null)
+ {
+ if (await DataStore.DeleteItemAsync(item.Id))
+ {
+ Items.Remove(item);
+ };
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/RefreshSampleViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/RefreshSampleViewModel.cs
new file mode 100644
index 0000000..94e503d
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/RefreshSampleViewModel.cs
@@ -0,0 +1,43 @@
+using CollectionViewSamples.Models;
+using System.Collections.ObjectModel;
+using System.Threading.Tasks;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public class RefreshSampleViewModel : BaseViewModel
-
+ {
+
+ public ObservableCollection
- Items { get; }
+ public Command LoadItemsCommand { get; }
+
+ public RefreshSampleViewModel()
+ {
+ Title = "Daten aktualisieren";
+ Items = new ObservableCollection
- ();
+ LoadItemsCommand = new Command(async () => await ExecuteLoadItemsCommand());
+ }
+
+ async Task ExecuteLoadItemsCommand()
+ {
+ try
+ {
+ Items.Clear();
+ var items = await DataStore.GetItemsAsync(true);
+ foreach (var item in items)
+ {
+ Items.Add(item);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+ public override Task Initialize()
+ {
+ IsBusy = true;
+ return base.Initialize();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/SelectSampleViewModel.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/SelectSampleViewModel.cs
new file mode 100644
index 0000000..4344f12
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/ViewModels/SelectSampleViewModel.cs
@@ -0,0 +1,84 @@
+using CollectionViewSamples.Models;
+using System.Collections.ObjectModel;
+using System.Threading.Tasks;
+using Microsoft.Maui.Controls;
+
+namespace CollectionViewSamples.ViewModels
+{
+ public class SelectSampleViewModel : BaseViewModel
-
+ {
+ private Item _selectedItem;
+ private string _selectedText = string.Empty;
+ private string _tappedText = string.Empty;
+
+ public ObservableCollection
- Items { get; }
+ public Command LoadItemsCommand { get; }
+ public Command
- ItemTapped { get; }
+
+ public SelectSampleViewModel()
+ {
+ Title = "Einträge selektieren";
+ Items = new ObservableCollection
- ();
+ LoadItemsCommand = new Command(async () => await ExecuteLoadItemsCommand());
+
+ ItemTapped = new Command
- (OnItemTapped);
+ }
+
+ async Task ExecuteLoadItemsCommand()
+ {
+ IsBusy = true;
+
+ try
+ {
+ Items.Clear();
+ var items = await DataStore.GetItemsAsync(true);
+ foreach (var item in items)
+ {
+ Items.Add(item);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ public override async Task Initialize()
+ {
+ await ExecuteLoadItemsCommand();
+ await base.Initialize();
+ }
+
+ public Item SelectedItem
+ {
+ get => _selectedItem;
+ set
+ {
+ SetProperty(ref _selectedItem, value);
+ OnItemSelected(value);
+ }
+ }
+
+
+ public string SelectedText
+ {
+ get => _selectedText;
+ set => SetProperty(ref _selectedText, value);
+ }
+ public string TappedText
+ {
+ get => _tappedText;
+ set => SetProperty(ref _tappedText, value);
+ }
+
+ void OnItemSelected(Item item)
+ {
+ SelectedText = item == null ? "Keine aktive Auswahl" : $"Aktive Auswahl ist: {item.Text}";
+ }
+
+ void OnItemTapped(Item item)
+ {
+ TappedText = item == null ? "Es wurde nichts geklickt" : $"Eintrag: {item.Text} wurde geklickt";
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml
new file mode 100644
index 0000000..74fd9a1
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml.cs
new file mode 100644
index 0000000..b2e5088
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/FirstSamplePage.xaml.cs
@@ -0,0 +1,25 @@
+using CollectionViewSamples.ViewModels;
+using Microsoft.Maui.Controls;
+
+
+namespace CollectionViewSamples.Views
+{
+
+ public partial class FirstSamplePage : ContentPage
+ {
+ private FirstSampleViewModel _viewModel;
+
+ public FirstSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = new FirstSampleViewModel();
+ }
+
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml
new file mode 100644
index 0000000..e830a5c
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml.cs
new file mode 100644
index 0000000..de281fe
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/GroupSamplePage.xaml.cs
@@ -0,0 +1,24 @@
+using CollectionViewSamples.ViewModels;
+using Microsoft.Maui.Controls;
+
+
+namespace CollectionViewSamples.Views
+{
+
+ public partial class GroupSamplePage : ContentPage
+ {
+ private GroupSampleViewModel _viewModel;
+
+ public GroupSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = new GroupSampleViewModel();
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml
new file mode 100644
index 0000000..85e0d88
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml.cs
new file mode 100644
index 0000000..5ff1479
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/MenuSamplePage.xaml.cs
@@ -0,0 +1,24 @@
+using CollectionViewSamples.ViewModels;
+using Microsoft.Maui.Controls;
+
+
+namespace CollectionViewSamples.Views
+{
+
+ public partial class MenuSamplePage : ContentPage
+ {
+ private MenuSampleViewModel _viewModel;
+
+ public MenuSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = new MenuSampleViewModel();
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml
new file mode 100644
index 0000000..0432424
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml.cs
new file mode 100644
index 0000000..fdd4397
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/RefreshSamplePage.xaml.cs
@@ -0,0 +1,24 @@
+using CollectionViewSamples.ViewModels;
+using Microsoft.Maui.Controls;
+
+
+namespace CollectionViewSamples.Views
+{
+
+ public partial class RefreshSamplePage : ContentPage
+ {
+ private RefreshSampleViewModel _viewModel;
+
+ public RefreshSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = new RefreshSampleViewModel();
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml
new file mode 100644
index 0000000..dc76be0
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml.cs b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml.cs
new file mode 100644
index 0000000..fc1cbd6
--- /dev/null
+++ b/Kap11/CollectionViewSamples/CollectionViewSamples/Views/SelectSamplePage.xaml.cs
@@ -0,0 +1,24 @@
+using CollectionViewSamples.ViewModels;
+using Microsoft.Maui.Controls;
+
+
+namespace CollectionViewSamples.Views
+{
+
+ public partial class SelectSamplePage : ContentPage
+ {
+ private SelectSampleViewModel _viewModel;
+
+ public SelectSamplePage()
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = new SelectSampleViewModel();
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..51d42ae
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..bed417d
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..a4439a1
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,13 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(CategoryPage), typeof(CategoryPage));
+ Routing.RegisterRoute(nameof(DishPage), typeof(DishPage));
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
new file mode 100644
index 0000000..6632a7c
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
@@ -0,0 +1,13 @@
+namespace ElVegetarianoFurio.Core;
+
+public interface INavigationService
+{
+ Task GoToAsync(string location);
+ Task GoToAsync(string location, bool animate);
+
+ Task GoToAsync(string location, Dictionary paramters);
+
+ Task GoToAsync(string location, bool animate, Dictionary paramters);
+}
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
new file mode 100644
index 0000000..b217d05
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
@@ -0,0 +1,26 @@
+namespace ElVegetarianoFurio.Core;
+
+public class NavigationService : INavigationService
+{
+ public async Task GoToAsync(string location)
+ {
+ await Shell.Current.GoToAsync(location);
+ }
+
+ public async Task GoToAsync(string location, bool animate)
+ {
+ await Shell.Current.GoToAsync(location, animate);
+ }
+
+ public async Task GoToAsync(string location, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, paramters);
+ }
+
+ public async Task GoToAsync(string location, bool animate, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, animate, paramters);
+ }
+}
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
new file mode 100644
index 0000000..3e87a00
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
@@ -0,0 +1,219 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+public class DummyDataService : IDataService
+{
+ private readonly List _categories;
+ private readonly List _dishes;
+
+ public DummyDataService()
+ {
+ _categories
+ = new List
+ {
+ new Category { Id = 1, Name = "Ensaladas", Description = "Salate" },
+ new Category { Id = 2, Name = "Cremas y sopas", Description = "Suppen" },
+ new Category { Id = 3, Name = "Tapas", Description = "Kleine Portionen" },
+ new Category { Id = 4, Name = "Platos principales", Description = "Hauptgerichte" },
+ new Category { Id = 5, Name = "Postres", Description = "Desserts" },
+ new Category { Id = 6, Name = "Bebidas", Description = "Getränke" }
+ };
+
+ _dishes = new List
+ {
+ new Dish
+ {
+ Id = 1,
+ Name = "Ensalada de Casa",
+ Description = "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ Price = 3.49m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 2,
+ Name = "Ensalada furia",
+ Description = "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ Price = 3.99m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 3,
+ Name = "Sopa de Tomate",
+ Description = "Tomatensuppe",
+ Price = 3.29m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 4,
+ Name = "Crema de verduras",
+ Description = "Gemüsecremesuppe",
+ Price = 4.39m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 5,
+ Name = "Tortilla de patatas",
+ Description = "Spanisches Omlett aus Eiern und Kartoffeln",
+ Price = 4.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 6,
+ Name = "Patatas bravas",
+ Description = "Gebratene Kartoffelstücke in pikanter Sauce",
+ Price = 3.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 7,
+ Name = "Pimientos al grill",
+ Description = "Gegrillte Paprika",
+ Price = 2.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 8,
+ Name = "Pan con alioli",
+ Description = "Ailoli mit Brot",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 9,
+ Name = "Pan con tomate y ajo",
+ Description = "Brot mit Tomate und Knoblauch",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 10,
+ Name = "Tortilla Chips",
+ Description = "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ Price = 1.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 11,
+ Name = "Chilli sin carne",
+ Description = "Vegetarisches Chilli, serviert mit Reis",
+ Price = 5.39m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 12,
+ Name = "Enchiladas de verduras",
+ Description = "Überbackene Maistortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 13,
+ Name = "Burritos de verduras",
+ Description = "Weizentortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 14,
+ Name = "Arroz con verduras",
+ Description = "Reis-/Gemüsepfanne",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 15,
+ Name = "Empanadas de espinacas y maíz",
+ Description = "Teigtaschen gefüllt mit Spinat und Mais",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 16,
+ Name = "Crema Catalana",
+ Description = "Katalanische Creme",
+ Price = 2.49m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 17,
+ Name = "Ensalada de frutas",
+ Description = "Obstsalat mit frischen Früchten",
+ Price = 2.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 18,
+ Name = "Churros",
+ Description = "Spritzgebäck mit Zucker",
+ Price = 1.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 19,
+ Name = "Agua mineral",
+ Description = "Mineralwasser",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 20,
+ Name = "Zumo de manzana",
+ Description = "Apfelsaft",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 21,
+ Name = "Limonada",
+ Description = "Zitronenlimonade",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 22,
+ Name = "Café",
+ Description = "Kaffee",
+ Price = 1.59m,
+ CategoryId = 6
+ }
+ };
+ }
+
+ public Task
> GetCategoriesAsync()
+ {
+ return Task.FromResult(_categories);
+ }
+
+ public Task> GetDishesAsync(int? categoryId = null)
+ {
+ return categoryId.HasValue
+ ? Task.FromResult(_dishes.Where(d => d.CategoryId == categoryId).ToList())
+ : Task.FromResult(_dishes);
+ }
+
+ public Task GetDishAsync(int id)
+ {
+ return Task.FromResult(_dishes.SingleOrDefault(d => d.Id == id));
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
new file mode 100644
index 0000000..ea070e4
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
@@ -0,0 +1,12 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+
+public interface IDataService
+{
+ Task> GetCategoriesAsync();
+ Task> GetDishesAsync(int? categoryId = null);
+ Task GetDishAsync(int id);
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..61016d4
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,63 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..f9253b8
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..078263d
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+
+ private readonly MainViewModel _viewModel;
+ public MainPage(MainViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+}
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
new file mode 100644
index 0000000..8cfc143
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
@@ -0,0 +1,58 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+public class MainViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToCategoryCommand { get; }
+
+ public ObservableCollection Categories { get; } =
+ new ObservableCollection();
+
+ public MainViewModel(IDataService dataService, INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadData());
+ NavigateToCategoryCommand = new Command(NavigateToCategory);
+ Title = "Start";
+ }
+
+ private async Task LoadData()
+ {
+ try
+ {
+ IsBusy = true;
+ Categories.Clear();
+ var categories = await _dataService.GetCategoriesAsync();
+
+ foreach (var category in categories)
+ {
+ Categories.Add(category);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ private async void NavigateToCategory(Category category)
+ {
+ await _navigationService.GoToAsync($"{nameof(CategoryPage)}?CategoryId={category.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadData();
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..4d93a0e
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,34 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using ElVegetarianoFurio.Menu;
+using ElVegetarianoFurio.Profile;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ return builder.Build();
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
new file mode 100644
index 0000000..2d13767
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Category
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
new file mode 100644
index 0000000..1391f58
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
new file mode 100644
index 0000000..ac2fcdc
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
@@ -0,0 +1,56 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(CategoryId), nameof(CategoryId))]
+public partial class CategoryPage : ContentPage
+{
+ private readonly CategoryViewModel _viewModel;
+
+ public CategoryPage(CategoryViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int CategoryId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.CategoryId = CategoryId;
+ // Hack. CategoryId ist 0, wenn wir
+ // ber das Men der Shell zur Seite navigieren
+ if(CategoryId == 0)
+ {
+ _viewModel.CategoryId = GetCategoryIdFromRoute();
+ }
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+
+ private int GetCategoryIdFromRoute()
+ {
+ // Hack: Die Shell kann derzeit deklarativ noch keine
+ // Routenparameter bei der Navigation an eine Seite
+ // weitergeben. Deshalb ermitteln wir hier die Route
+ // der aktuellen Seite und geben hart codiert die ID
+ // zurck. Die Lsung ist nich schn und sollte
+ // umgestellt werden, sobald die Shell bei der
+ // deklarativen Navigation Argumente bergeben kann
+ var route = Shell.Current.CurrentState.Location
+ .OriginalString.Split("/").LastOrDefault();
+ return route switch
+ {
+ "ensaladas" => 1,
+ "sopas" => 2,
+ "tapas" => 3,
+ "principales" => 4,
+ "postres" => 5,
+ "bebidas" => 6,
+ _ => 0,
+ };
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
new file mode 100644
index 0000000..736ab91
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
@@ -0,0 +1,68 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class CategoryViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+ private Category _category;
+ private int _categoryId;
+
+ public CategoryViewModel(IDataService dataService,
+ INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadDataAsync());
+ NavigateToDishCommand = new Command(NavigateToDish);
+ }
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToDishCommand { get; }
+
+ public ObservableCollection Dishes { get; set; }
+ = new ObservableCollection();
+
+ public Category Category
+ {
+ get => _category;
+ set => SetProperty(ref _category, value);
+ }
+
+ public int CategoryId
+ {
+ get => _categoryId;
+ set => SetProperty(ref _categoryId, value);
+ }
+
+ private async Task LoadDataAsync()
+ {
+ Dishes.Clear();
+
+ Category = (await _dataService.GetCategoriesAsync())
+ .First(c => c.Id == CategoryId);
+ var dishes = await _dataService.GetDishesAsync(CategoryId);
+
+ foreach (var dish in dishes)
+ {
+ Dishes.Add(dish);
+ }
+ }
+
+ private async void NavigateToDish(Dish dish)
+ {
+ await _navigationService.GoToAsync($"{nameof(DishPage)}?DishId={dish.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadDataAsync();
+ await base.Initialize();
+ }
+}
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
new file mode 100644
index 0000000..ce1d48d
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Dish
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ public decimal Price { get; set; }
+ public int CategoryId { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
new file mode 100644
index 0000000..0923dac
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
new file mode 100644
index 0000000..544f253
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
@@ -0,0 +1,27 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(DishId), nameof(DishId))]
+public partial class DishPage : ContentPage
+{
+ private readonly DishViewModel _viewModel;
+
+ public DishPage(DishViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int DishId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.DishId = DishId;
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
new file mode 100644
index 0000000..f149c72
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
@@ -0,0 +1,35 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class DishViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private Dish _dish;
+ private int _dishId;
+
+ public Dish Dish
+ {
+ get => _dish;
+ set => SetProperty(ref _dish, value);
+ }
+
+ public DishViewModel(IDataService dataService)
+ {
+ _dataService = dataService;
+ }
+
+ public int DishId
+ {
+ get => _dishId;
+ set => SetProperty(ref _dishId, value);
+ }
+
+ public override async Task Initialize()
+ {
+ Dish = await _dataService.GetDishAsync(DishId);
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap11/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..51d42ae
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..82e0c47
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..a4439a1
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,13 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(CategoryPage), typeof(CategoryPage));
+ Routing.RegisterRoute(nameof(DishPage), typeof(DishPage));
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
new file mode 100644
index 0000000..722c4c5
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Core
+{
+ // Generated by IconFont2Code: https://andreinitescu.github.io/IconFont2Code
+ // If you change the class to 'public' in order to use it outside its assembly
+ // you should also change the fields from 'const' to 'public static readonly'
+ static class FaSolid
+ {
+ public const string Home = "\uf015";
+ public const string Utensils = "\uf2e7";
+ public const string Carrot = "\uf787";
+ public const string UtensilSpoon = "\uf2e5";
+ public const string PepperHot = "\uf816";
+ public const string IceCream = "\uf810";
+ public const string GlassCheers = "\uf79f";
+ public const string UserCircle = "\uf2bd";
+ public const string MapMarkedAlt = "\uf5a0";
+ public const string Phone = "\uf095";
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
new file mode 100644
index 0000000..6632a7c
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
@@ -0,0 +1,13 @@
+namespace ElVegetarianoFurio.Core;
+
+public interface INavigationService
+{
+ Task GoToAsync(string location);
+ Task GoToAsync(string location, bool animate);
+
+ Task GoToAsync(string location, Dictionary paramters);
+
+ Task GoToAsync(string location, bool animate, Dictionary paramters);
+}
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
new file mode 100644
index 0000000..b217d05
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
@@ -0,0 +1,26 @@
+namespace ElVegetarianoFurio.Core;
+
+public class NavigationService : INavigationService
+{
+ public async Task GoToAsync(string location)
+ {
+ await Shell.Current.GoToAsync(location);
+ }
+
+ public async Task GoToAsync(string location, bool animate)
+ {
+ await Shell.Current.GoToAsync(location, animate);
+ }
+
+ public async Task GoToAsync(string location, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, paramters);
+ }
+
+ public async Task GoToAsync(string location, bool animate, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, animate, paramters);
+ }
+}
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
new file mode 100644
index 0000000..3e87a00
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
@@ -0,0 +1,219 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+public class DummyDataService : IDataService
+{
+ private readonly List _categories;
+ private readonly List _dishes;
+
+ public DummyDataService()
+ {
+ _categories
+ = new List
+ {
+ new Category { Id = 1, Name = "Ensaladas", Description = "Salate" },
+ new Category { Id = 2, Name = "Cremas y sopas", Description = "Suppen" },
+ new Category { Id = 3, Name = "Tapas", Description = "Kleine Portionen" },
+ new Category { Id = 4, Name = "Platos principales", Description = "Hauptgerichte" },
+ new Category { Id = 5, Name = "Postres", Description = "Desserts" },
+ new Category { Id = 6, Name = "Bebidas", Description = "Getränke" }
+ };
+
+ _dishes = new List
+ {
+ new Dish
+ {
+ Id = 1,
+ Name = "Ensalada de Casa",
+ Description = "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ Price = 3.49m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 2,
+ Name = "Ensalada furia",
+ Description = "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ Price = 3.99m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 3,
+ Name = "Sopa de Tomate",
+ Description = "Tomatensuppe",
+ Price = 3.29m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 4,
+ Name = "Crema de verduras",
+ Description = "Gemüsecremesuppe",
+ Price = 4.39m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 5,
+ Name = "Tortilla de patatas",
+ Description = "Spanisches Omlett aus Eiern und Kartoffeln",
+ Price = 4.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 6,
+ Name = "Patatas bravas",
+ Description = "Gebratene Kartoffelstücke in pikanter Sauce",
+ Price = 3.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 7,
+ Name = "Pimientos al grill",
+ Description = "Gegrillte Paprika",
+ Price = 2.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 8,
+ Name = "Pan con alioli",
+ Description = "Ailoli mit Brot",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 9,
+ Name = "Pan con tomate y ajo",
+ Description = "Brot mit Tomate und Knoblauch",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 10,
+ Name = "Tortilla Chips",
+ Description = "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ Price = 1.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 11,
+ Name = "Chilli sin carne",
+ Description = "Vegetarisches Chilli, serviert mit Reis",
+ Price = 5.39m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 12,
+ Name = "Enchiladas de verduras",
+ Description = "Überbackene Maistortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 13,
+ Name = "Burritos de verduras",
+ Description = "Weizentortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 14,
+ Name = "Arroz con verduras",
+ Description = "Reis-/Gemüsepfanne",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 15,
+ Name = "Empanadas de espinacas y maíz",
+ Description = "Teigtaschen gefüllt mit Spinat und Mais",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 16,
+ Name = "Crema Catalana",
+ Description = "Katalanische Creme",
+ Price = 2.49m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 17,
+ Name = "Ensalada de frutas",
+ Description = "Obstsalat mit frischen Früchten",
+ Price = 2.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 18,
+ Name = "Churros",
+ Description = "Spritzgebäck mit Zucker",
+ Price = 1.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 19,
+ Name = "Agua mineral",
+ Description = "Mineralwasser",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 20,
+ Name = "Zumo de manzana",
+ Description = "Apfelsaft",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 21,
+ Name = "Limonada",
+ Description = "Zitronenlimonade",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 22,
+ Name = "Café",
+ Description = "Kaffee",
+ Price = 1.59m,
+ CategoryId = 6
+ }
+ };
+ }
+
+ public Task> GetCategoriesAsync()
+ {
+ return Task.FromResult(_categories);
+ }
+
+ public Task> GetDishesAsync(int? categoryId = null)
+ {
+ return categoryId.HasValue
+ ? Task.FromResult(_dishes.Where(d => d.CategoryId == categoryId).ToList())
+ : Task.FromResult(_dishes);
+ }
+
+ public Task GetDishAsync(int id)
+ {
+ return Task.FromResult(_dishes.SingleOrDefault(d => d.Id == id));
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
new file mode 100644
index 0000000..ea070e4
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
@@ -0,0 +1,12 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+
+public interface IDataService
+{
+ Task> GetCategoriesAsync();
+ Task> GetDishesAsync(int? categoryId = null);
+ Task GetDishAsync(int id);
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..1327b8e
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,110 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..42f26f4
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..078263d
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+
+ private readonly MainViewModel _viewModel;
+ public MainPage(MainViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+}
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
new file mode 100644
index 0000000..8cfc143
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
@@ -0,0 +1,58 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+public class MainViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToCategoryCommand { get; }
+
+ public ObservableCollection Categories { get; } =
+ new ObservableCollection();
+
+ public MainViewModel(IDataService dataService, INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadData());
+ NavigateToCategoryCommand = new Command(NavigateToCategory);
+ Title = "Start";
+ }
+
+ private async Task LoadData()
+ {
+ try
+ {
+ IsBusy = true;
+ Categories.Clear();
+ var categories = await _dataService.GetCategoriesAsync();
+
+ foreach (var category in categories)
+ {
+ Categories.Add(category);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ private async void NavigateToCategory(Category category)
+ {
+ await _navigationService.GoToAsync($"{nameof(CategoryPage)}?CategoryId={category.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadData();
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..4829080
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,37 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using ElVegetarianoFurio.Menu;
+using ElVegetarianoFurio.Profile;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ fonts.AddFont("Font Awesome 5 Free-Solid-900.otf", "Fa-Solid");
+ fonts.AddFont("ShadowsIntoLight-Regular.ttf", "Shadows");
+ fonts.AddFont("Sofia-Regular.ttf", "Sofia");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ return builder.Build();
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
new file mode 100644
index 0000000..2d13767
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Category
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
new file mode 100644
index 0000000..b1f4b8b
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
new file mode 100644
index 0000000..ac2fcdc
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
@@ -0,0 +1,56 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(CategoryId), nameof(CategoryId))]
+public partial class CategoryPage : ContentPage
+{
+ private readonly CategoryViewModel _viewModel;
+
+ public CategoryPage(CategoryViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int CategoryId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.CategoryId = CategoryId;
+ // Hack. CategoryId ist 0, wenn wir
+ // ber das Men der Shell zur Seite navigieren
+ if(CategoryId == 0)
+ {
+ _viewModel.CategoryId = GetCategoryIdFromRoute();
+ }
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+
+ private int GetCategoryIdFromRoute()
+ {
+ // Hack: Die Shell kann derzeit deklarativ noch keine
+ // Routenparameter bei der Navigation an eine Seite
+ // weitergeben. Deshalb ermitteln wir hier die Route
+ // der aktuellen Seite und geben hart codiert die ID
+ // zurck. Die Lsung ist nich schn und sollte
+ // umgestellt werden, sobald die Shell bei der
+ // deklarativen Navigation Argumente bergeben kann
+ var route = Shell.Current.CurrentState.Location
+ .OriginalString.Split("/").LastOrDefault();
+ return route switch
+ {
+ "ensaladas" => 1,
+ "sopas" => 2,
+ "tapas" => 3,
+ "principales" => 4,
+ "postres" => 5,
+ "bebidas" => 6,
+ _ => 0,
+ };
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
new file mode 100644
index 0000000..736ab91
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
@@ -0,0 +1,68 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class CategoryViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+ private Category _category;
+ private int _categoryId;
+
+ public CategoryViewModel(IDataService dataService,
+ INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadDataAsync());
+ NavigateToDishCommand = new Command(NavigateToDish);
+ }
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToDishCommand { get; }
+
+ public ObservableCollection Dishes { get; set; }
+ = new ObservableCollection();
+
+ public Category Category
+ {
+ get => _category;
+ set => SetProperty(ref _category, value);
+ }
+
+ public int CategoryId
+ {
+ get => _categoryId;
+ set => SetProperty(ref _categoryId, value);
+ }
+
+ private async Task LoadDataAsync()
+ {
+ Dishes.Clear();
+
+ Category = (await _dataService.GetCategoriesAsync())
+ .First(c => c.Id == CategoryId);
+ var dishes = await _dataService.GetDishesAsync(CategoryId);
+
+ foreach (var dish in dishes)
+ {
+ Dishes.Add(dish);
+ }
+ }
+
+ private async void NavigateToDish(Dish dish)
+ {
+ await _navigationService.GoToAsync($"{nameof(DishPage)}?DishId={dish.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadDataAsync();
+ await base.Initialize();
+ }
+}
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
new file mode 100644
index 0000000..ce1d48d
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Dish
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ public decimal Price { get; set; }
+ public int CategoryId { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
new file mode 100644
index 0000000..034c2ea
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
new file mode 100644
index 0000000..544f253
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
@@ -0,0 +1,27 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(DishId), nameof(DishId))]
+public partial class DishPage : ContentPage
+{
+ private readonly DishViewModel _viewModel;
+
+ public DishPage(DishViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int DishId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.DishId = DishId;
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
new file mode 100644
index 0000000..f149c72
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
@@ -0,0 +1,35 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class DishViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private Dish _dish;
+ private int _dishId;
+
+ public Dish Dish
+ {
+ get => _dish;
+ set => SetProperty(ref _dish, value);
+ }
+
+ public DishViewModel(IDataService dataService)
+ {
+ _dataService = dataService;
+ }
+
+ public int DishId
+ {
+ get => _dishId;
+ set => SetProperty(ref _dishId, value);
+ }
+
+ public override async Task Initialize()
+ {
+ Dish = await _dataService.GetDishAsync(DishId);
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf
new file mode 100644
index 0000000..8fb28d5
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf
new file mode 100644
index 0000000..b7bc796
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf
new file mode 100644
index 0000000..aaee088
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg
new file mode 100644
index 0000000..5287632
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg
new file mode 100644
index 0000000..d2e1756
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg
new file mode 100644
index 0000000..ad87a41
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg
new file mode 100644
index 0000000..4daa8f9
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg
new file mode 100644
index 0000000..cc079b2
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg
new file mode 100644
index 0000000..c6c5c3b
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
new file mode 100644
index 0000000..572cad7
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
@@ -0,0 +1,111 @@
+category1.jpg
+https://unsplash.com/photos/IGfIGP5ONV0
+Unsplash / Anna Pelzer
+
+category2.jpg
+https://unsplash.com/photos/OMcrCX6wDpU
+Unsplash / Jade Aucamp
+
+category3.jpg
+https://pixabay.com/de/photos/creme-k%C3%A4se-tomate-sousse-chips-1503526/
+Pixybay / hamomdomingues
+
+category4.jpg
+https://www.pexels.com/photo/blur-bowl-close-up-cook-461326/
+Pexels / Pixabay
+
+category5.jpg
+https://pixabay.com/de/photos/eisbecher-speiseeis-eiscreme-2194070/
+Pixybay / silviarita
+
+category6.jpg
+https://mavl.io/photo/7331/summer-drink
+Mavl / picjumbo.com
+
+dish1.jpg
+https://unsplash.com/photos/MlPD-AzZYMg
+Unsplash / Louis Hansel
+
+dish2.jpg
+https://unsplash.com/photos/AiHJiRCwB3w
+Unsplash / Yoav Aziz
+
+dish3.jpg
+https://www.pexels.com/photo/appetizer-bowl-bread-breakfast-539451/
+Pexels / Foodie Factor
+
+dish4.jpg
+https://pixabay.com/de/photos/erbsensuppe-suppe-vorspeise-2786133/
+Pixabay / Ritae
+
+dish5.jpg
+https://pxhere.com/en/photo/758610
+pxhere
+
+dish6.jpg
+https://unsplash.com/photos/vzIgmhbEN9w
+Unsplash / Nacho Carretero Molero
+
+dish7.jpg
+https://pxhere.com/de/photo/459409
+pxhere
+
+dish8.jpg
+https://pxhere.com/es/photo/607309
+pxhere
+
+dish9.jpg
+https://pxhere.com/es/photo/529102
+pxhere
+
+dish10.jpg
+https://www.rawpixel.com/image/448047/free-photo-image-dip-mexican-cuisine-appetite
+rawpixel / Jakub Kapusnak
+
+dish11.jpg
+https://pixabay.com/de/photos/tjena-k%C3%BCche-chili-con-carne-reis-3175645/
+pixabay / TJENA
+
+dish12.jpg
+https://unsplash.com/photos/xsfX3AqLDKo
+Unsplash / Alexandra Golovac
+
+dish13.jpg
+https://pixabay.com/de/photos/burrito-tortilla-lebensmittel-4126116/
+pixabay / nevena1313
+
+dish14.jpg
+https://pixnio.com/food-and-drink/rice-food-dinner-lunch-dish-meal-vegetable-meat-delicious
+pixnio
+
+dish15.jpg
+https://pixabay.com/de/photos/empanadas-empanaditas-partei-macht-3410288/
+pixybay / Emersontc
+
+dish16.jpg
+https://pxhere.com/en/photo/863645
+pxhere
+
+
+dish17.jpg
+https://pixnio.com/flora-plants/fruits/fruit-salad-diet-food-nutrition-delicious-kiwi-sweet
+pixnio
+
+dish18.jpg
+https://pixabay.com/de/photos/churros-backen-cookies-dessert-2188871/
+pixabay / Daria-Yakovleva
+
+dish19.jpg
+https://pxhere.com/en/photo/1274085
+
+dish20.jpg
+https://pxhere.com/en/photo/1582781
+pxhere / rawpixel.com
+
+dish21.jpg
+https://unsplash.com/photos/p5EiqkBYIEE
+Unsplash / Francesca Hotchin
+
+dish22.jpg
+https://pxhere.com/en/photo/655302
+pxhere
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg
new file mode 100644
index 0000000..b4a8e6b
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg
new file mode 100644
index 0000000..af6ca2f
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg
new file mode 100644
index 0000000..be404cc
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg
new file mode 100644
index 0000000..83e883b
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg
new file mode 100644
index 0000000..60a51f3
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg
new file mode 100644
index 0000000..f833169
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg
new file mode 100644
index 0000000..a2a3be6
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg
new file mode 100644
index 0000000..b2f1d29
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg
new file mode 100644
index 0000000..a94addb
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg
new file mode 100644
index 0000000..e1b4bed
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg
new file mode 100644
index 0000000..eb5d8ab
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg
new file mode 100644
index 0000000..0106493
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg
new file mode 100644
index 0000000..72cbf4f
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg
new file mode 100644
index 0000000..6cfcda0
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg
new file mode 100644
index 0000000..5101c63
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg
new file mode 100644
index 0000000..33ed103
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg
new file mode 100644
index 0000000..96b9fb1
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg
new file mode 100644
index 0000000..e1d88a6
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg
new file mode 100644
index 0000000..fcd2757
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg
new file mode 100644
index 0000000..9eb85e9
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg
new file mode 100644
index 0000000..b6b9d0b
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg
new file mode 100644
index 0000000..f5f56a0
Binary files /dev/null and b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg differ
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
new file mode 100644
index 0000000..dfa107d
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
@@ -0,0 +1,59 @@
+All pictures are taken from the following sources:
+
+- Pexels
+- Pixabay
+- Pixnio
+- Pxhere
+- Rawpixl
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+ilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Pixnio
+https://pixnio.com/de/
+https://pixnio.com/public-domain-definition
+Hochwertige urheberrechts-freundliche Bilder, urheberrechtsfreie Bilder und Bilder ohne Beschränkung für deren Verwendung. Explizit in der Public Domain platzierte Bilder, keine Rechte vorbehalten. Public Domain Bilder können für beliebige Zwecke genutzt werden, nutzen Sie diese frei für persönliche oder kommerzielle Nutzung.
+
+## Pxhere
+https://pxhere.com/de/license
+
+ It's hard to understand complex licenses that is why all photos on PxHere are licensed under the Creative Commons Zero (CC0) license. This means the pictures are completely free to be used for any legal purpose.
+ The pictures are free for personal and even for commercial use.
+ You can modify, copy and distribute the photos.
+ All without asking for permission or setting a link to the source. So, attribution is not required.
+ The only restriction is that identifiable people may not appear in a bad light or in a way that they may find offensive, unless they give their consent.
+ The CC0 license was released by the non-profit organization Creative Commons (CC). Get more information about Creative Commons images and the license on the official license page.
+
+## Rawpixl
+https://www.rawpixel.com/services/image-licenses
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap12/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample.sln b/Kap12/ImagesSample/ImagesSample.sln
new file mode 100644
index 0000000..948982a
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ImagesSample", "ImagesSample\ImagesSample.csproj", "{123C2EB1-FC1A-473E-A376-2FBA047A2866}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Release|Any CPU.Build.0 = Release|Any CPU
+ {123C2EB1-FC1A-473E-A376-2FBA047A2866}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap12/ImagesSample/ImagesSample/App.xaml b/Kap12/ImagesSample/ImagesSample/App.xaml
new file mode 100644
index 0000000..e6f5f36
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/App.xaml.cs b/Kap12/ImagesSample/ImagesSample/App.xaml.cs
new file mode 100644
index 0000000..429cd52
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ImagesSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/AppShell.xaml b/Kap12/ImagesSample/ImagesSample/AppShell.xaml
new file mode 100644
index 0000000..e10e415
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/AppShell.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/AppShell.xaml.cs b/Kap12/ImagesSample/ImagesSample/AppShell.xaml.cs
new file mode 100644
index 0000000..8100622
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace ImagesSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/FaIcons.cs b/Kap12/ImagesSample/ImagesSample/FaIcons.cs
new file mode 100644
index 0000000..89cbacb
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/FaIcons.cs
@@ -0,0 +1,23 @@
+namespace ImagesSample
+{
+ // Generated by IconFont2Code: https://andreinitescu.github.io/IconFont2Code
+ // If you change the class to 'public' in order to use it outside its assembly
+ // you should also change the fields from 'const' to 'public static readonly'
+ static class FaIcons
+ {
+ ///
+ /// Zeigt ein Zeitungssymbol an
+ ///
+ public const string Newspaper = "\uf1ea";
+
+
+ ///
+ /// Symbol zum Teilen von Inhalten
+ ///
+ public const string ShareSquare = "\uf14d";
+ public const string Envelope = "\uf0e0";
+ public const string User = "\uf007";
+ public const string Clock = "\uf017";
+
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/ImageResourceExtension.cs b/Kap12/ImagesSample/ImagesSample/ImageResourceExtension.cs
new file mode 100644
index 0000000..f06422b
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/ImageResourceExtension.cs
@@ -0,0 +1,26 @@
+using System;
+using System.Reflection;
+using Microsoft.Maui.Controls;
+using Microsoft.Maui.Controls.Xaml;
+
+namespace ImagesSample
+{
+ [ContentProperty(nameof(Source))]
+ public class ImageResourceExtension : IMarkupExtension
+ {
+ public string Source { get; set; }
+
+ public object ProvideValue(IServiceProvider serviceProvider)
+ {
+ if (Source == null)
+ {
+ return null;
+ }
+
+
+ var imageSource = ImageSource.FromResource(Source, typeof(ImageResourceExtension).GetTypeInfo().Assembly);
+
+ return imageSource;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Images/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Images/qualitybytes_sample.png
new file mode 100644
index 0000000..2535793
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Images/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/ImagesSample.csproj b/Kap12/ImagesSample/ImagesSample/ImagesSample.csproj
new file mode 100644
index 0000000..42b1432
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/ImagesSample.csproj
@@ -0,0 +1,111 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ImagesSample
+ true
+ true
+ enable
+
+
+ ImagesSample
+
+
+ com.companyname.imagessample
+ 3500CF4A-910B-42AC-BC2F-C1322D938386
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/MainPage.xaml b/Kap12/ImagesSample/ImagesSample/MainPage.xaml
new file mode 100644
index 0000000..f9a9233
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/MainPage.xaml.cs b/Kap12/ImagesSample/ImagesSample/MainPage.xaml.cs
new file mode 100644
index 0000000..c29b6ca
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace ImagesSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap12/ImagesSample/ImagesSample/MauiProgram.cs b/Kap12/ImagesSample/ImagesSample/MauiProgram.cs
new file mode 100644
index 0000000..af0f5e2
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/MauiProgram.cs
@@ -0,0 +1,21 @@
+namespace ImagesSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ fonts.AddFont("IndieFlower-Regular.ttf", "IndieFlower");
+ fonts.AddFont("Font Awesome 5 Free-Regular-400.otf", "FontAwesome");
+ fonts.AddFont("DancingScript-VariableFont_wght.ttf", "DancingScript");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/AndroidManifest.xml b/Kap12/ImagesSample/ImagesSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainActivity.cs b/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..b193067
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ImagesSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainApplication.cs b/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..dee95cc
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ImagesSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/Resources/values/colors.xml b/Kap12/ImagesSample/ImagesSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-hdpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-hdpi/qualitybytes_sample.png
new file mode 100644
index 0000000..92040e5
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-hdpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-ldpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-ldpi/qualitybytes_sample.png
new file mode 100644
index 0000000..cbd26fc
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-ldpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-mdpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-mdpi/qualitybytes_sample.png
new file mode 100644
index 0000000..9678705
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-mdpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xhdpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xhdpi/qualitybytes_sample.png
new file mode 100644
index 0000000..531f341
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xhdpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxhdpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxhdpi/qualitybytes_sample.png
new file mode 100644
index 0000000..2166c03
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxhdpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxxhdpi/qualitybytes_sample.png b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxxhdpi/qualitybytes_sample.png
new file mode 100644
index 0000000..69cc168
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Android/drawable/drawable-xxxhdpi/qualitybytes_sample.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..40bad27
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ImagesSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Info.plist b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Program.cs b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..865a389
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ImagesSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/Main.cs b/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..c38de69
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ImagesSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/tizen-manifest.xml b/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..3238dd4
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..ed3d0da
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml.cs b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..b5d51b3
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ImagesSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-100.png b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-100.png
new file mode 100644
index 0000000..92040e5
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-100.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-125.png b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-125.png
new file mode 100644
index 0000000..cbd26fc
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-125.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-150.png b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-150.png
new file mode 100644
index 0000000..9678705
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-150.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-200.png b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-200.png
new file mode 100644
index 0000000..531f341
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-200.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-400.png b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-400.png
new file mode 100644
index 0000000..2166c03
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Assets/qualitybytes_sample.scale-400.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Package.appxmanifest b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/Windows/app.manifest b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..dd10965
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/iOS/AppDelegate.cs b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..40bad27
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ImagesSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Info.plist b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Program.cs b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..865a389
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ImagesSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap12/ImagesSample/ImagesSample/Properties/launchSettings.json b/Kap12/ImagesSample/ImagesSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appicon.svg b/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appiconfg.svg b/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Fonts/DancingScript-VariableFont_wght.ttf b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/DancingScript-VariableFont_wght.ttf
new file mode 100644
index 0000000..6f55454
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/DancingScript-VariableFont_wght.ttf differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Fonts/Font Awesome 5 Free-Regular-400.otf b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/Font Awesome 5 Free-Regular-400.otf
new file mode 100644
index 0000000..bd594a9
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/Font Awesome 5 Free-Regular-400.otf differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Fonts/IndieFlower-Regular.ttf b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/IndieFlower-Regular.ttf
new file mode 100644
index 0000000..1070aac
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/IndieFlower-Regular.ttf differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Images/dotnet_bot.svg b/Kap12/ImagesSample/ImagesSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Images/qualitybytes_sample_maui.png b/Kap12/ImagesSample/ImagesSample/Resources/Images/qualitybytes_sample_maui.png
new file mode 100644
index 0000000..bcfee69
Binary files /dev/null and b/Kap12/ImagesSample/ImagesSample/Resources/Images/qualitybytes_sample_maui.png differ
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Raw/AboutAssets.txt b/Kap12/ImagesSample/ImagesSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Splash/splash.svg b/Kap12/ImagesSample/ImagesSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Styles/Colors.xaml b/Kap12/ImagesSample/ImagesSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Resources/Styles/Styles.xaml b/Kap12/ImagesSample/ImagesSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml b/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml
new file mode 100644
index 0000000..85129bb
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml.cs b/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml.cs
new file mode 100644
index 0000000..0059510
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/EmbeddedImagesSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace ImagesSample.Views
+{
+
+ public partial class EmbeddedImagesSamplePage : ContentPage
+ {
+ public EmbeddedImagesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml b/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml
new file mode 100644
index 0000000..3867f66
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml.cs b/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml.cs
new file mode 100644
index 0000000..47db421
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/FontIconsSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace ImagesSample.Views
+{
+
+ public partial class FontIconsSamplePage : ContentPage
+ {
+ public FontIconsSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml b/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml
new file mode 100644
index 0000000..6bbc267
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml.cs b/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml.cs
new file mode 100644
index 0000000..43ca386
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/FontsSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace ImagesSample.Views
+{
+
+ public partial class FontsSamplePage : ContentPage
+ {
+ public FontsSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml b/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml
new file mode 100644
index 0000000..7a6315f
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml.cs b/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml.cs
new file mode 100644
index 0000000..04ae64f
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/MauiImagesSamplePage.xaml.cs
@@ -0,0 +1,18 @@
+using Microsoft.Maui.Controls;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ImagesSample.Views
+{
+
+ public partial class MauiImagesSamplePage : ContentPage
+ {
+ public MauiImagesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml b/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml
new file mode 100644
index 0000000..d0128fc
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml.cs b/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml.cs
new file mode 100644
index 0000000..662bcd8
--- /dev/null
+++ b/Kap12/ImagesSample/ImagesSample/Views/PlattformImagesSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace ImagesSample.Views
+{
+
+ public partial class PlattformImagesSamplePage : ContentPage
+ {
+ public PlattformImagesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..6581a67
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..6b1d42e
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..a4439a1
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,13 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(CategoryPage), typeof(CategoryPage));
+ Routing.RegisterRoute(nameof(DishPage), typeof(DishPage));
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
new file mode 100644
index 0000000..722c4c5
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Core
+{
+ // Generated by IconFont2Code: https://andreinitescu.github.io/IconFont2Code
+ // If you change the class to 'public' in order to use it outside its assembly
+ // you should also change the fields from 'const' to 'public static readonly'
+ static class FaSolid
+ {
+ public const string Home = "\uf015";
+ public const string Utensils = "\uf2e7";
+ public const string Carrot = "\uf787";
+ public const string UtensilSpoon = "\uf2e5";
+ public const string PepperHot = "\uf816";
+ public const string IceCream = "\uf810";
+ public const string GlassCheers = "\uf79f";
+ public const string UserCircle = "\uf2bd";
+ public const string MapMarkedAlt = "\uf5a0";
+ public const string Phone = "\uf095";
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
new file mode 100644
index 0000000..6632a7c
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
@@ -0,0 +1,13 @@
+namespace ElVegetarianoFurio.Core;
+
+public interface INavigationService
+{
+ Task GoToAsync(string location);
+ Task GoToAsync(string location, bool animate);
+
+ Task GoToAsync(string location, Dictionary paramters);
+
+ Task GoToAsync(string location, bool animate, Dictionary paramters);
+}
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
new file mode 100644
index 0000000..b217d05
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
@@ -0,0 +1,26 @@
+namespace ElVegetarianoFurio.Core;
+
+public class NavigationService : INavigationService
+{
+ public async Task GoToAsync(string location)
+ {
+ await Shell.Current.GoToAsync(location);
+ }
+
+ public async Task GoToAsync(string location, bool animate)
+ {
+ await Shell.Current.GoToAsync(location, animate);
+ }
+
+ public async Task GoToAsync(string location, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, paramters);
+ }
+
+ public async Task GoToAsync(string location, bool animate, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, animate, paramters);
+ }
+}
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
new file mode 100644
index 0000000..3e87a00
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
@@ -0,0 +1,219 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+public class DummyDataService : IDataService
+{
+ private readonly List _categories;
+ private readonly List _dishes;
+
+ public DummyDataService()
+ {
+ _categories
+ = new List
+ {
+ new Category { Id = 1, Name = "Ensaladas", Description = "Salate" },
+ new Category { Id = 2, Name = "Cremas y sopas", Description = "Suppen" },
+ new Category { Id = 3, Name = "Tapas", Description = "Kleine Portionen" },
+ new Category { Id = 4, Name = "Platos principales", Description = "Hauptgerichte" },
+ new Category { Id = 5, Name = "Postres", Description = "Desserts" },
+ new Category { Id = 6, Name = "Bebidas", Description = "Getränke" }
+ };
+
+ _dishes = new List
+ {
+ new Dish
+ {
+ Id = 1,
+ Name = "Ensalada de Casa",
+ Description = "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ Price = 3.49m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 2,
+ Name = "Ensalada furia",
+ Description = "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ Price = 3.99m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 3,
+ Name = "Sopa de Tomate",
+ Description = "Tomatensuppe",
+ Price = 3.29m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 4,
+ Name = "Crema de verduras",
+ Description = "Gemüsecremesuppe",
+ Price = 4.39m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 5,
+ Name = "Tortilla de patatas",
+ Description = "Spanisches Omlett aus Eiern und Kartoffeln",
+ Price = 4.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 6,
+ Name = "Patatas bravas",
+ Description = "Gebratene Kartoffelstücke in pikanter Sauce",
+ Price = 3.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 7,
+ Name = "Pimientos al grill",
+ Description = "Gegrillte Paprika",
+ Price = 2.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 8,
+ Name = "Pan con alioli",
+ Description = "Ailoli mit Brot",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 9,
+ Name = "Pan con tomate y ajo",
+ Description = "Brot mit Tomate und Knoblauch",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 10,
+ Name = "Tortilla Chips",
+ Description = "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ Price = 1.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 11,
+ Name = "Chilli sin carne",
+ Description = "Vegetarisches Chilli, serviert mit Reis",
+ Price = 5.39m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 12,
+ Name = "Enchiladas de verduras",
+ Description = "Überbackene Maistortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 13,
+ Name = "Burritos de verduras",
+ Description = "Weizentortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 14,
+ Name = "Arroz con verduras",
+ Description = "Reis-/Gemüsepfanne",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 15,
+ Name = "Empanadas de espinacas y maíz",
+ Description = "Teigtaschen gefüllt mit Spinat und Mais",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 16,
+ Name = "Crema Catalana",
+ Description = "Katalanische Creme",
+ Price = 2.49m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 17,
+ Name = "Ensalada de frutas",
+ Description = "Obstsalat mit frischen Früchten",
+ Price = 2.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 18,
+ Name = "Churros",
+ Description = "Spritzgebäck mit Zucker",
+ Price = 1.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 19,
+ Name = "Agua mineral",
+ Description = "Mineralwasser",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 20,
+ Name = "Zumo de manzana",
+ Description = "Apfelsaft",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 21,
+ Name = "Limonada",
+ Description = "Zitronenlimonade",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 22,
+ Name = "Café",
+ Description = "Kaffee",
+ Price = 1.59m,
+ CategoryId = 6
+ }
+ };
+ }
+
+ public Task> GetCategoriesAsync()
+ {
+ return Task.FromResult(_categories);
+ }
+
+ public Task> GetDishesAsync(int? categoryId = null)
+ {
+ return categoryId.HasValue
+ ? Task.FromResult(_dishes.Where(d => d.CategoryId == categoryId).ToList())
+ : Task.FromResult(_dishes);
+ }
+
+ public Task GetDishAsync(int id)
+ {
+ return Task.FromResult(_dishes.SingleOrDefault(d => d.Id == id));
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
new file mode 100644
index 0000000..ea070e4
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
@@ -0,0 +1,12 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+
+public interface IDataService
+{
+ Task> GetCategoriesAsync();
+ Task> GetDishesAsync(int? categoryId = null);
+ Task GetDishAsync(int id);
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..7d1dec7
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,113 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..42f26f4
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..078263d
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+
+ private readonly MainViewModel _viewModel;
+ public MainPage(MainViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+}
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
new file mode 100644
index 0000000..8cfc143
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
@@ -0,0 +1,58 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+public class MainViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToCategoryCommand { get; }
+
+ public ObservableCollection Categories { get; } =
+ new ObservableCollection();
+
+ public MainViewModel(IDataService dataService, INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadData());
+ NavigateToCategoryCommand = new Command(NavigateToCategory);
+ Title = "Start";
+ }
+
+ private async Task LoadData()
+ {
+ try
+ {
+ IsBusy = true;
+ Categories.Clear();
+ var categories = await _dataService.GetCategoriesAsync();
+
+ foreach (var category in categories)
+ {
+ Categories.Add(category);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ private async void NavigateToCategory(Category category)
+ {
+ await _navigationService.GoToAsync($"{nameof(CategoryPage)}?CategoryId={category.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadData();
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..4829080
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,37 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using ElVegetarianoFurio.Menu;
+using ElVegetarianoFurio.Profile;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ fonts.AddFont("Font Awesome 5 Free-Solid-900.otf", "Fa-Solid");
+ fonts.AddFont("ShadowsIntoLight-Regular.ttf", "Shadows");
+ fonts.AddFont("Sofia-Regular.ttf", "Sofia");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ return builder.Build();
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
new file mode 100644
index 0000000..2d13767
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Category
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
new file mode 100644
index 0000000..b7dedd6
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
new file mode 100644
index 0000000..ac2fcdc
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
@@ -0,0 +1,56 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(CategoryId), nameof(CategoryId))]
+public partial class CategoryPage : ContentPage
+{
+ private readonly CategoryViewModel _viewModel;
+
+ public CategoryPage(CategoryViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int CategoryId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.CategoryId = CategoryId;
+ // Hack. CategoryId ist 0, wenn wir
+ // ber das Men der Shell zur Seite navigieren
+ if(CategoryId == 0)
+ {
+ _viewModel.CategoryId = GetCategoryIdFromRoute();
+ }
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+
+ private int GetCategoryIdFromRoute()
+ {
+ // Hack: Die Shell kann derzeit deklarativ noch keine
+ // Routenparameter bei der Navigation an eine Seite
+ // weitergeben. Deshalb ermitteln wir hier die Route
+ // der aktuellen Seite und geben hart codiert die ID
+ // zurck. Die Lsung ist nich schn und sollte
+ // umgestellt werden, sobald die Shell bei der
+ // deklarativen Navigation Argumente bergeben kann
+ var route = Shell.Current.CurrentState.Location
+ .OriginalString.Split("/").LastOrDefault();
+ return route switch
+ {
+ "ensaladas" => 1,
+ "sopas" => 2,
+ "tapas" => 3,
+ "principales" => 4,
+ "postres" => 5,
+ "bebidas" => 6,
+ _ => 0,
+ };
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
new file mode 100644
index 0000000..736ab91
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
@@ -0,0 +1,68 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class CategoryViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+ private Category _category;
+ private int _categoryId;
+
+ public CategoryViewModel(IDataService dataService,
+ INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadDataAsync());
+ NavigateToDishCommand = new Command(NavigateToDish);
+ }
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToDishCommand { get; }
+
+ public ObservableCollection Dishes { get; set; }
+ = new ObservableCollection();
+
+ public Category Category
+ {
+ get => _category;
+ set => SetProperty(ref _category, value);
+ }
+
+ public int CategoryId
+ {
+ get => _categoryId;
+ set => SetProperty(ref _categoryId, value);
+ }
+
+ private async Task LoadDataAsync()
+ {
+ Dishes.Clear();
+
+ Category = (await _dataService.GetCategoriesAsync())
+ .First(c => c.Id == CategoryId);
+ var dishes = await _dataService.GetDishesAsync(CategoryId);
+
+ foreach (var dish in dishes)
+ {
+ Dishes.Add(dish);
+ }
+ }
+
+ private async void NavigateToDish(Dish dish)
+ {
+ await _navigationService.GoToAsync($"{nameof(DishPage)}?DishId={dish.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadDataAsync();
+ await base.Initialize();
+ }
+}
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
new file mode 100644
index 0000000..ce1d48d
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Dish
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ public decimal Price { get; set; }
+ public int CategoryId { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
new file mode 100644
index 0000000..cccccf2
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
new file mode 100644
index 0000000..544f253
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
@@ -0,0 +1,27 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(DishId), nameof(DishId))]
+public partial class DishPage : ContentPage
+{
+ private readonly DishViewModel _viewModel;
+
+ public DishPage(DishViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int DishId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.DishId = DishId;
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
new file mode 100644
index 0000000..f149c72
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
@@ -0,0 +1,35 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class DishViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private Dish _dish;
+ private int _dishId;
+
+ public Dish Dish
+ {
+ get => _dish;
+ set => SetProperty(ref _dish, value);
+ }
+
+ public DishViewModel(IDataService dataService)
+ {
+ _dataService = dataService;
+ }
+
+ public int DishId
+ {
+ get => _dishId;
+ set => SetProperty(ref _dishId, value);
+ }
+
+ public override async Task Initialize()
+ {
+ Dish = await _dataService.GetDishAsync(DishId);
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf
new file mode 100644
index 0000000..8fb28d5
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf
new file mode 100644
index 0000000..b7bc796
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf
new file mode 100644
index 0000000..aaee088
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg
new file mode 100644
index 0000000..5287632
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg
new file mode 100644
index 0000000..d2e1756
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg
new file mode 100644
index 0000000..ad87a41
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg
new file mode 100644
index 0000000..4daa8f9
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg
new file mode 100644
index 0000000..cc079b2
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg
new file mode 100644
index 0000000..c6c5c3b
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
new file mode 100644
index 0000000..572cad7
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
@@ -0,0 +1,111 @@
+category1.jpg
+https://unsplash.com/photos/IGfIGP5ONV0
+Unsplash / Anna Pelzer
+
+category2.jpg
+https://unsplash.com/photos/OMcrCX6wDpU
+Unsplash / Jade Aucamp
+
+category3.jpg
+https://pixabay.com/de/photos/creme-k%C3%A4se-tomate-sousse-chips-1503526/
+Pixybay / hamomdomingues
+
+category4.jpg
+https://www.pexels.com/photo/blur-bowl-close-up-cook-461326/
+Pexels / Pixabay
+
+category5.jpg
+https://pixabay.com/de/photos/eisbecher-speiseeis-eiscreme-2194070/
+Pixybay / silviarita
+
+category6.jpg
+https://mavl.io/photo/7331/summer-drink
+Mavl / picjumbo.com
+
+dish1.jpg
+https://unsplash.com/photos/MlPD-AzZYMg
+Unsplash / Louis Hansel
+
+dish2.jpg
+https://unsplash.com/photos/AiHJiRCwB3w
+Unsplash / Yoav Aziz
+
+dish3.jpg
+https://www.pexels.com/photo/appetizer-bowl-bread-breakfast-539451/
+Pexels / Foodie Factor
+
+dish4.jpg
+https://pixabay.com/de/photos/erbsensuppe-suppe-vorspeise-2786133/
+Pixabay / Ritae
+
+dish5.jpg
+https://pxhere.com/en/photo/758610
+pxhere
+
+dish6.jpg
+https://unsplash.com/photos/vzIgmhbEN9w
+Unsplash / Nacho Carretero Molero
+
+dish7.jpg
+https://pxhere.com/de/photo/459409
+pxhere
+
+dish8.jpg
+https://pxhere.com/es/photo/607309
+pxhere
+
+dish9.jpg
+https://pxhere.com/es/photo/529102
+pxhere
+
+dish10.jpg
+https://www.rawpixel.com/image/448047/free-photo-image-dip-mexican-cuisine-appetite
+rawpixel / Jakub Kapusnak
+
+dish11.jpg
+https://pixabay.com/de/photos/tjena-k%C3%BCche-chili-con-carne-reis-3175645/
+pixabay / TJENA
+
+dish12.jpg
+https://unsplash.com/photos/xsfX3AqLDKo
+Unsplash / Alexandra Golovac
+
+dish13.jpg
+https://pixabay.com/de/photos/burrito-tortilla-lebensmittel-4126116/
+pixabay / nevena1313
+
+dish14.jpg
+https://pixnio.com/food-and-drink/rice-food-dinner-lunch-dish-meal-vegetable-meat-delicious
+pixnio
+
+dish15.jpg
+https://pixabay.com/de/photos/empanadas-empanaditas-partei-macht-3410288/
+pixybay / Emersontc
+
+dish16.jpg
+https://pxhere.com/en/photo/863645
+pxhere
+
+
+dish17.jpg
+https://pixnio.com/flora-plants/fruits/fruit-salad-diet-food-nutrition-delicious-kiwi-sweet
+pixnio
+
+dish18.jpg
+https://pixabay.com/de/photos/churros-backen-cookies-dessert-2188871/
+pixabay / Daria-Yakovleva
+
+dish19.jpg
+https://pxhere.com/en/photo/1274085
+
+dish20.jpg
+https://pxhere.com/en/photo/1582781
+pxhere / rawpixel.com
+
+dish21.jpg
+https://unsplash.com/photos/p5EiqkBYIEE
+Unsplash / Francesca Hotchin
+
+dish22.jpg
+https://pxhere.com/en/photo/655302
+pxhere
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg
new file mode 100644
index 0000000..b4a8e6b
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg
new file mode 100644
index 0000000..af6ca2f
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg
new file mode 100644
index 0000000..be404cc
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg
new file mode 100644
index 0000000..83e883b
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg
new file mode 100644
index 0000000..60a51f3
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg
new file mode 100644
index 0000000..f833169
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg
new file mode 100644
index 0000000..a2a3be6
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg
new file mode 100644
index 0000000..b2f1d29
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg
new file mode 100644
index 0000000..a94addb
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg
new file mode 100644
index 0000000..e1b4bed
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg
new file mode 100644
index 0000000..eb5d8ab
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg
new file mode 100644
index 0000000..0106493
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg
new file mode 100644
index 0000000..72cbf4f
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg
new file mode 100644
index 0000000..6cfcda0
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg
new file mode 100644
index 0000000..5101c63
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg
new file mode 100644
index 0000000..33ed103
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg
new file mode 100644
index 0000000..96b9fb1
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg
new file mode 100644
index 0000000..e1d88a6
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg
new file mode 100644
index 0000000..fcd2757
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg
new file mode 100644
index 0000000..9eb85e9
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg
new file mode 100644
index 0000000..b6b9d0b
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg
new file mode 100644
index 0000000..f5f56a0
Binary files /dev/null and b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg differ
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
new file mode 100644
index 0000000..dfa107d
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
@@ -0,0 +1,59 @@
+All pictures are taken from the following sources:
+
+- Pexels
+- Pixabay
+- Pixnio
+- Pxhere
+- Rawpixl
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+ilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Pixnio
+https://pixnio.com/de/
+https://pixnio.com/public-domain-definition
+Hochwertige urheberrechts-freundliche Bilder, urheberrechtsfreie Bilder und Bilder ohne Beschränkung für deren Verwendung. Explizit in der Public Domain platzierte Bilder, keine Rechte vorbehalten. Public Domain Bilder können für beliebige Zwecke genutzt werden, nutzen Sie diese frei für persönliche oder kommerzielle Nutzung.
+
+## Pxhere
+https://pxhere.com/de/license
+
+ It's hard to understand complex licenses that is why all photos on PxHere are licensed under the Creative Commons Zero (CC0) license. This means the pictures are completely free to be used for any legal purpose.
+ The pictures are free for personal and even for commercial use.
+ You can modify, copy and distribute the photos.
+ All without asking for permission or setting a link to the source. So, attribution is not required.
+ The only restriction is that identifiable people may not appear in a bad light or in a way that they may find offensive, unless they give their consent.
+ The CC0 license was released by the non-profit organization Creative Commons (CC). Get more information about Creative Commons images and the license on the official license page.
+
+## Rawpixl
+https://www.rawpixel.com/services/image-licenses
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml
new file mode 100644
index 0000000..f551fef
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs
new file mode 100644
index 0000000..a0dd304
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Resources.Styles;
+
+public partial class AppStyles : ResourceDictionary
+{
+ public AppStyles()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap13/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample.sln b/Kap13/StylesSample/StylesSample.sln
new file mode 100644
index 0000000..4418a96
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "StylesSample", "StylesSample\StylesSample.csproj", "{14B3C832-B19C-40B1-88AB-36689DEFEC35}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Release|Any CPU.Build.0 = Release|Any CPU
+ {14B3C832-B19C-40B1-88AB-36689DEFEC35}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap13/StylesSample/StylesSample/App.xaml b/Kap13/StylesSample/StylesSample/App.xaml
new file mode 100644
index 0000000..211774a
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/App.xaml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/App.xaml.cs b/Kap13/StylesSample/StylesSample/App.xaml.cs
new file mode 100644
index 0000000..9d96175
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace StylesSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/AppShell.xaml b/Kap13/StylesSample/StylesSample/AppShell.xaml
new file mode 100644
index 0000000..01604d2
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/AppShell.xaml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/AppShell.xaml.cs b/Kap13/StylesSample/StylesSample/AppShell.xaml.cs
new file mode 100644
index 0000000..f6b71d4
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/AppShell.xaml.cs
@@ -0,0 +1,9 @@
+namespace StylesSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/MainPage.xaml b/Kap13/StylesSample/StylesSample/MainPage.xaml
new file mode 100644
index 0000000..18c0af7
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/MainPage.xaml.cs b/Kap13/StylesSample/StylesSample/MainPage.xaml.cs
new file mode 100644
index 0000000..65167c7
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace StylesSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap13/StylesSample/StylesSample/MauiProgram.cs b/Kap13/StylesSample/StylesSample/MauiProgram.cs
new file mode 100644
index 0000000..b0681dc
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/MauiProgram.cs
@@ -0,0 +1,18 @@
+namespace StylesSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ return builder.Build();
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Android/AndroidManifest.xml b/Kap13/StylesSample/StylesSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Android/MainActivity.cs b/Kap13/StylesSample/StylesSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..af7e912
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace StylesSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Android/MainApplication.cs b/Kap13/StylesSample/StylesSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..292dfb1
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace StylesSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Android/Resources/values/colors.xml b/Kap13/StylesSample/StylesSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..0993048
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace StylesSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Info.plist b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Program.cs b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..4fb5c84
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace StylesSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Tizen/Main.cs b/Kap13/StylesSample/StylesSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..a7a04c2
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace StylesSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Tizen/tizen-manifest.xml b/Kap13/StylesSample/StylesSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..9c016d6
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml b/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..c1ab87d
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml.cs b/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..59f61a7
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace StylesSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Windows/Package.appxmanifest b/Kap13/StylesSample/StylesSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/Windows/app.manifest b/Kap13/StylesSample/StylesSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..775ab20
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/iOS/AppDelegate.cs b/Kap13/StylesSample/StylesSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..0993048
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace StylesSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap13/StylesSample/StylesSample/Platforms/iOS/Info.plist b/Kap13/StylesSample/StylesSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap13/StylesSample/StylesSample/Platforms/iOS/Program.cs b/Kap13/StylesSample/StylesSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..4fb5c84
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace StylesSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap13/StylesSample/StylesSample/Properties/launchSettings.json b/Kap13/StylesSample/StylesSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/AppIcon/appicon.svg b/Kap13/StylesSample/StylesSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/AppIcon/appiconfg.svg b/Kap13/StylesSample/StylesSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap13/StylesSample/StylesSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap13/StylesSample/StylesSample/Resources/Images/dotnet_bot.svg b/Kap13/StylesSample/StylesSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap13/StylesSample/StylesSample/Resources/Raw/AboutAssets.txt b/Kap13/StylesSample/StylesSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap13/StylesSample/StylesSample/Resources/Splash/splash.svg b/Kap13/StylesSample/StylesSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/Colors.xaml b/Kap13/StylesSample/StylesSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml b/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml
new file mode 100644
index 0000000..7fe2b7b
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml
@@ -0,0 +1,10 @@
+
+
+
+ #F79330
+ #2097C8
+ #091F35
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml.cs b/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml.cs
new file mode 100644
index 0000000..dafe3ed
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/DarkTheme.xaml.cs
@@ -0,0 +1,9 @@
+namespace StylesSample.Resources.Styles;
+
+public partial class DarkTheme : ResourceDictionary
+{
+ public DarkTheme()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml b/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml
new file mode 100644
index 0000000..ffc407c
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml
@@ -0,0 +1,10 @@
+
+
+
+ DarkGreen
+ DeepPink
+ PaleGreen
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml.cs b/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml.cs
new file mode 100644
index 0000000..d8105bb
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/GreenTheme.xaml.cs
@@ -0,0 +1,9 @@
+namespace StylesSample.Resources.Styles;
+
+public partial class GreenTheme : ResourceDictionary
+ {
+ public GreenTheme()
+ {
+ InitializeComponent();
+ }
+ }
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml b/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml
new file mode 100644
index 0000000..4800bf4
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml
@@ -0,0 +1,10 @@
+
+
+
+ #091F35
+ #2097C8
+ White
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml.cs b/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml.cs
new file mode 100644
index 0000000..28e4ec3
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/LightTheme.xaml.cs
@@ -0,0 +1,9 @@
+namespace StylesSample.Resources.Styles;
+
+public partial class LightTheme : ResourceDictionary
+ {
+ public LightTheme()
+ {
+ InitializeComponent();
+ }
+ }
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.css b/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.css
new file mode 100644
index 0000000..bfa70ea
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.css
@@ -0,0 +1,35 @@
+verticalstacklayout {
+ padding: 40;
+}
+
+.error {
+ background-color:red;
+ color: white;
+ }
+
+.warning {
+ background-color: orange;
+ color: white;
+}
+
+.success {
+ background-color: darkseagreen;
+ color: white;
+}
+
+.large {
+ font-size: 30;
+ padding: 20;
+}
+
+.medium {
+ font-size: 20;
+ padding: 10;
+}
+
+.small {
+ font-size: 10;
+ padding: 5;
+}
+
+
diff --git a/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.xaml b/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/StylesSample.csproj b/Kap13/StylesSample/StylesSample/StylesSample.csproj
new file mode 100644
index 0000000..0c9dfd0
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/StylesSample.csproj
@@ -0,0 +1,87 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ StylesSample
+ true
+ true
+ enable
+
+
+ StylesSample
+
+
+ com.companyname.stylessample
+ 54981FBE-2FE7-4C28-B39D-07DA07C591A6
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ %(Filename)
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml
new file mode 100644
index 0000000..5ad3827
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml.cs
new file mode 100644
index 0000000..30787fd
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/CssSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace StylesSample.Views
+{
+
+ public partial class CssSamplePage : ContentPage
+ {
+ public CssSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml
new file mode 100644
index 0000000..dd33a50
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml
@@ -0,0 +1,36 @@
+
+
+
+
+ #091F35
+ #2097C8
+ White
+ #F79330
+ #2097C8
+ White
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml.cs
new file mode 100644
index 0000000..f3ec5d6
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/DarkModeLightModeSamplePage.xaml.cs
@@ -0,0 +1,41 @@
+namespace StylesSample.Views;
+public partial class DarkModeLightModeSamplePage : ContentPage
+{
+ public DarkModeLightModeSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ protected override void OnAppearing()
+ {
+ base.OnAppearing();
+ DisplayCurrentTheme();
+ Application.Current.RequestedThemeChanged += Application_ThemeChanged;
+ }
+ protected override void OnDisappearing()
+ {
+ base.OnDisappearing();
+ Application.Current.RequestedThemeChanged -= Application_ThemeChanged;
+ }
+
+ private void Application_ThemeChanged(object sender, AppThemeChangedEventArgs e)
+ {
+ DisplayCurrentTheme();
+ }
+
+ private void DisplayCurrentTheme()
+ {
+ switch (Application.Current.RequestedTheme)
+ {
+ case AppTheme.Unspecified:
+ CurrentThemeLabel.Text = "Das aktuelle Theme ist nicht spezifiziert";
+ break;
+ case AppTheme.Dark:
+ CurrentThemeLabel.Text = "Das aktuelle Theme ist dunkel";
+ break;
+ case AppTheme.Light:
+ CurrentThemeLabel.Text = "Das aktuelle Theme ist hell";
+ break;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml
new file mode 100644
index 0000000..24438f8
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml
@@ -0,0 +1,32 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml.cs
new file mode 100644
index 0000000..6bfa225
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ExplicitStylesSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace StylesSample.Views
+{
+
+ public partial class ExplicitStylesSamplePage : ContentPage
+ {
+ public ExplicitStylesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml
new file mode 100644
index 0000000..aa66d5c
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml
@@ -0,0 +1,32 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml.cs
new file mode 100644
index 0000000..6f0dca6
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ImplicitStylesSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace StylesSample.Views
+{
+
+ public partial class ImplicitStylesSamplePage : ContentPage
+ {
+ public ImplicitStylesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml
new file mode 100644
index 0000000..44dcacb
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml.cs
new file mode 100644
index 0000000..f89c1a3
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/StyleClassesSamplePage.xaml.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+using Microsoft.Maui.Controls;
+
+
+namespace StylesSample.Views
+{
+
+ public partial class StyleClassesSamplePage : ContentPage
+ {
+ public StyleClassesSamplePage()
+ {
+ InitializeComponent();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml b/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml
new file mode 100644
index 0000000..14dd646
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml.cs b/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml.cs
new file mode 100644
index 0000000..c093291
--- /dev/null
+++ b/Kap13/StylesSample/StylesSample/Views/ThemesSamplePage.xaml.cs
@@ -0,0 +1,32 @@
+using StylesSample.Resources.Styles;
+
+namespace StylesSample.Views;
+
+public partial class ThemesSamplePage : ContentPage
+{
+ public ThemesSamplePage()
+ {
+ InitializeComponent();
+ }
+
+ private void LightTheme_Clicked(object sender, EventArgs e)
+ {
+ ChangeTheme(new LightTheme());
+ }
+
+ private void DarkTheme_Clicked(object sender, EventArgs e)
+ {
+ ChangeTheme(new DarkTheme());
+ }
+
+ private void GreenTheme_Clicked(object sender, EventArgs e)
+ {
+ ChangeTheme(new GreenTheme());
+ }
+
+ private void ChangeTheme(ResourceDictionary theme)
+ {
+ Resources.MergedDictionaries.Remove(Resources.MergedDictionaries.Last());
+ Resources.MergedDictionaries.Add(theme);
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio.sln b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio.sln
new file mode 100644
index 0000000..e06707a
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ElVegetarianoFurio", "ElVegetarianoFurio\ElVegetarianoFurio.csproj", "{7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7E9FC7EE-FEEF-4B94-8F1E-4179D817E356}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
new file mode 100644
index 0000000..6581a67
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
new file mode 100644
index 0000000..22615be
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
new file mode 100644
index 0000000..96e23db
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
new file mode 100644
index 0000000..a4439a1
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/AppShell.xaml.cs
@@ -0,0 +1,13 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(CategoryPage), typeof(CategoryPage));
+ Routing.RegisterRoute(nameof(DishPage), typeof(DishPage));
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
new file mode 100644
index 0000000..03d0240
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/BaseViewModel.cs
@@ -0,0 +1,69 @@
+using System.ComponentModel;
+using System.Runtime.CompilerServices;
+
+namespace ElVegetarianoFurio.Core;
+
+public abstract class BaseViewModel : INotifyPropertyChanged
+{
+ private bool _isBusy;
+ private string _title = string.Empty;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+
+ ///
+ /// IsBusy gibt an, ob gerade ein längerer Aufruf läuft.
+ /// Die Eigenschaft muss explizit durch den Entwickler gesetzt werden.
+ /// Sie kann genutzt werden, um in der View eine Ladeanimation anzuzeigen
+ ///
+ public bool IsBusy
+ {
+ get => _isBusy;
+ set => SetProperty(ref _isBusy, value);
+ }
+
+ ///
+ /// Titel des ViewModels. Dient zur Anzeige der Überschrift in der View
+ ///
+ public string Title
+ {
+ get => _title;
+ set => SetProperty(ref _title, value);
+ }
+
+ public virtual Task Initialize()
+ {
+ return Task.FromResult(default(object));
+ }
+
+ ///
+ /// Aktualisiert den Wert eines Felds und löst das Ereignis
+ /// aus, falls erforderlich.
+ ///
+ /// Datentyp des zu ändernden Felds
+ /// das zu ändernde Feld
+ /// neuer Wert
+ /// Name der Eigenschaft, die das Feld umschließt.
+ /// Methode, die Aufgerufen werden soll, falls
+ /// der Wert verändert wurde.
+ ///
+ protected bool SetProperty(ref T backingStore, T value,
+ [CallerMemberName] string propertyName = "",
+ Action onChanged = null)
+ {
+ if (EqualityComparer.Default.Equals(backingStore, value))
+ {
+ return false;
+ }
+
+ backingStore = value;
+ onChanged?.Invoke();
+ OnPropertyChanged(propertyName);
+ return true;
+ }
+
+ protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
+ {
+ PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
new file mode 100644
index 0000000..722c4c5
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/FaSolid.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Core
+{
+ // Generated by IconFont2Code: https://andreinitescu.github.io/IconFont2Code
+ // If you change the class to 'public' in order to use it outside its assembly
+ // you should also change the fields from 'const' to 'public static readonly'
+ static class FaSolid
+ {
+ public const string Home = "\uf015";
+ public const string Utensils = "\uf2e7";
+ public const string Carrot = "\uf787";
+ public const string UtensilSpoon = "\uf2e5";
+ public const string PepperHot = "\uf816";
+ public const string IceCream = "\uf810";
+ public const string GlassCheers = "\uf79f";
+ public const string UserCircle = "\uf2bd";
+ public const string MapMarkedAlt = "\uf5a0";
+ public const string Phone = "\uf095";
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
new file mode 100644
index 0000000..6632a7c
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/INavigationService.cs
@@ -0,0 +1,13 @@
+namespace ElVegetarianoFurio.Core;
+
+public interface INavigationService
+{
+ Task GoToAsync(string location);
+ Task GoToAsync(string location, bool animate);
+
+ Task GoToAsync(string location, Dictionary paramters);
+
+ Task GoToAsync(string location, bool animate, Dictionary paramters);
+}
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
new file mode 100644
index 0000000..b217d05
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Core/NavigationService.cs
@@ -0,0 +1,26 @@
+namespace ElVegetarianoFurio.Core;
+
+public class NavigationService : INavigationService
+{
+ public async Task GoToAsync(string location)
+ {
+ await Shell.Current.GoToAsync(location);
+ }
+
+ public async Task GoToAsync(string location, bool animate)
+ {
+ await Shell.Current.GoToAsync(location, animate);
+ }
+
+ public async Task GoToAsync(string location, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, paramters);
+ }
+
+ public async Task GoToAsync(string location, bool animate, Dictionary paramters)
+ {
+ await Shell.Current.GoToAsync(location, animate, paramters);
+ }
+}
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
new file mode 100644
index 0000000..3e87a00
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/DummyDataService.cs
@@ -0,0 +1,219 @@
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+public class DummyDataService : IDataService
+{
+ private readonly List _categories;
+ private readonly List _dishes;
+
+ public DummyDataService()
+ {
+ _categories
+ = new List
+ {
+ new Category { Id = 1, Name = "Ensaladas", Description = "Salate" },
+ new Category { Id = 2, Name = "Cremas y sopas", Description = "Suppen" },
+ new Category { Id = 3, Name = "Tapas", Description = "Kleine Portionen" },
+ new Category { Id = 4, Name = "Platos principales", Description = "Hauptgerichte" },
+ new Category { Id = 5, Name = "Postres", Description = "Desserts" },
+ new Category { Id = 6, Name = "Bebidas", Description = "Getränke" }
+ };
+
+ _dishes = new List
+ {
+ new Dish
+ {
+ Id = 1,
+ Name = "Ensalada de Casa",
+ Description = "Salat nach Art des Hauses. Gemischter Salat, Mais, Paprika, Käse, Zwiebeln",
+ Price = 3.49m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 2,
+ Name = "Ensalada furia",
+ Description = "Gemischter Salat mit Chillis, Paprika, Radieschen und Zwiebeln (scharf!)",
+ Price = 3.99m,
+ CategoryId = 1
+ },
+ new Dish
+ {
+ Id = 3,
+ Name = "Sopa de Tomate",
+ Description = "Tomatensuppe",
+ Price = 3.29m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 4,
+ Name = "Crema de verduras",
+ Description = "Gemüsecremesuppe",
+ Price = 4.39m,
+ CategoryId = 2
+ },
+ new Dish
+ {
+ Id = 5,
+ Name = "Tortilla de patatas",
+ Description = "Spanisches Omlett aus Eiern und Kartoffeln",
+ Price = 4.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 6,
+ Name = "Patatas bravas",
+ Description = "Gebratene Kartoffelstücke in pikanter Sauce",
+ Price = 3.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 7,
+ Name = "Pimientos al grill",
+ Description = "Gegrillte Paprika",
+ Price = 2.99m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 8,
+ Name = "Pan con alioli",
+ Description = "Ailoli mit Brot",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 9,
+ Name = "Pan con tomate y ajo",
+ Description = "Brot mit Tomate und Knoblauch",
+ Price = 2.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 10,
+ Name = "Tortilla Chips",
+ Description = "Tortilla Chips mit Salsa Dip, Guacamole oder Alioli",
+ Price = 1.29m,
+ CategoryId = 3
+ },
+ new Dish
+ {
+ Id = 11,
+ Name = "Chilli sin carne",
+ Description = "Vegetarisches Chilli, serviert mit Reis",
+ Price = 5.39m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 12,
+ Name = "Enchiladas de verduras",
+ Description = "Überbackene Maistortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 13,
+ Name = "Burritos de verduras",
+ Description = "Weizentortillas gefüllt mit Gemüse",
+ Price = 4.99m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 14,
+ Name = "Arroz con verduras",
+ Description = "Reis-/Gemüsepfanne",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 15,
+ Name = "Empanadas de espinacas y maíz",
+ Description = "Teigtaschen gefüllt mit Spinat und Mais",
+ Price = 4.49m,
+ CategoryId = 4
+ },
+ new Dish
+ {
+ Id = 16,
+ Name = "Crema Catalana",
+ Description = "Katalanische Creme",
+ Price = 2.49m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 17,
+ Name = "Ensalada de frutas",
+ Description = "Obstsalat mit frischen Früchten",
+ Price = 2.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 18,
+ Name = "Churros",
+ Description = "Spritzgebäck mit Zucker",
+ Price = 1.99m,
+ CategoryId = 5
+ },
+ new Dish
+ {
+ Id = 19,
+ Name = "Agua mineral",
+ Description = "Mineralwasser",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 20,
+ Name = "Zumo de manzana",
+ Description = "Apfelsaft",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 21,
+ Name = "Limonada",
+ Description = "Zitronenlimonade",
+ Price = 1.59m,
+ CategoryId = 6
+ },
+ new Dish
+ {
+ Id = 22,
+ Name = "Café",
+ Description = "Kaffee",
+ Price = 1.59m,
+ CategoryId = 6
+ }
+ };
+ }
+
+ public Task> GetCategoriesAsync()
+ {
+ return Task.FromResult(_categories);
+ }
+
+ public Task> GetDishesAsync(int? categoryId = null)
+ {
+ return categoryId.HasValue
+ ? Task.FromResult(_dishes.Where(d => d.CategoryId == categoryId).ToList())
+ : Task.FromResult(_dishes);
+ }
+
+ public Task GetDishAsync(int id)
+ {
+ return Task.FromResult(_dishes.SingleOrDefault(d => d.Id == id));
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
new file mode 100644
index 0000000..ea070e4
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/IDataService.cs
@@ -0,0 +1,12 @@
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio.Data;
+
+public interface IDataService
+{
+ Task> GetCategoriesAsync();
+ Task> GetDishesAsync(int? categoryId = null);
+ Task GetDishAsync(int id);
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/WebApiDataService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/WebApiDataService.cs
new file mode 100644
index 0000000..1f017e8
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Data/WebApiDataService.cs
@@ -0,0 +1,72 @@
+using ElVegetarianoFurio.Menu;
+using MonkeyCache.FileStore;
+using System.Text.Json;
+
+namespace ElVegetarianoFurio.Data;
+
+public class WebApiDataService : IDataService
+{
+ private static readonly HttpClient _client = new HttpClient
+ {
+ BaseAddress = new Uri(
+ "https://my-json-server.typicode.com/AndreKraemer/vegi-data/")
+ };
+
+ private static JsonSerializerOptions _serializerOptions = new JsonSerializerOptions
+ {
+ PropertyNameCaseInsensitive = true,
+ PropertyNamingPolicy = JsonNamingPolicy.CamelCase
+ };
+
+
+ public Task> GetCategoriesAsync()
+ {
+ return GetCachedAsync>("categories", TimeSpan.FromDays(1));
+ }
+
+ public async Task> GetDishesAsync(int? categoryId = null)
+ {
+ var dishes = await GetCachedAsync>("dishes");
+ return categoryId.HasValue ?
+ dishes.Where(d => d.CategoryId == categoryId.Value).ToList() :
+ dishes;
+ }
+
+ public async Task GetDishAsync(int id)
+ {
+ return await GetCachedAsync($"dishes/{id}", TimeSpan.FromHours(1));
+ }
+
+ private async Task GetCachedAsync(string url, TimeSpan? cacheTime = null)
+ {
+ // Wenn keine Internetverbindung besteht, gecachte Daten zurückgeben,
+ // auch wenn diese bereits abgelaufen sind.
+ if (Connectivity.NetworkAccess != NetworkAccess.Internet)
+ {
+ return Barrel.Current.Get(url);
+ }
+
+ // Falls Internetverbindung besteht und es nicht abgelaufene
+ // gecachte Daten gibt, diese zurückgeben
+ if (!Barrel.Current.IsExpired(url))
+ {
+ return Barrel.Current.Get(url);
+ }
+
+ // Daten vom Webservice abrufen
+ try
+ {
+ var json = await _client.GetStringAsync(url);
+ var result = JsonSerializer.Deserialize(json, _serializerOptions);
+
+ // Daten mit einer Lebensdauer von 5 Minuten im Cache ablegen
+ Barrel.Current.Add(url, result, cacheTime ?? TimeSpan.FromMinutes(5));
+ return result;
+ }
+ catch (HttpRequestException)
+ {
+ return default; // Im Fall einer Exception ein leeres Objekt zurückgeben
+ }
+ }
+
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
new file mode 100644
index 0000000..abccb11
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/ElVegetarianoFurio.csproj
@@ -0,0 +1,117 @@
+
+
+
+ net6.0-android;net6.0-ios;net6.0-maccatalyst
+ $(TargetFrameworks);net6.0-windows10.0.19041.0
+
+
+ Exe
+ ElVegetarianoFurio
+ true
+ true
+ enable
+
+
+ ElVegetarianoFurio
+
+
+ com.companyname.elvegetarianofurio
+ FAE1F078-1007-4406-B7D9-C9E32D4CBB7F
+
+
+ 1.0
+ 1
+
+ 14.2
+ 14.0
+ 21.0
+ 10.0.17763.0
+ 10.0.17763.0
+ 6.5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
new file mode 100644
index 0000000..42f26f4
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
new file mode 100644
index 0000000..078263d
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainPage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio;
+
+public partial class MainPage : ContentPage
+{
+
+ private readonly MainViewModel _viewModel;
+ public MainPage(MainViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+}
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
new file mode 100644
index 0000000..8cfc143
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MainViewModel.cs
@@ -0,0 +1,58 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+using ElVegetarianoFurio.Menu;
+
+namespace ElVegetarianoFurio;
+public class MainViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToCategoryCommand { get; }
+
+ public ObservableCollection Categories { get; } =
+ new ObservableCollection();
+
+ public MainViewModel(IDataService dataService, INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadData());
+ NavigateToCategoryCommand = new Command(NavigateToCategory);
+ Title = "Start";
+ }
+
+ private async Task LoadData()
+ {
+ try
+ {
+ IsBusy = true;
+ Categories.Clear();
+ var categories = await _dataService.GetCategoriesAsync();
+
+ foreach (var category in categories)
+ {
+ Categories.Add(category);
+ }
+ }
+ finally
+ {
+ IsBusy = false;
+ }
+ }
+
+ private async void NavigateToCategory(Category category)
+ {
+ await _navigationService.GoToAsync($"{nameof(CategoryPage)}?CategoryId={category.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadData();
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
new file mode 100644
index 0000000..6130085
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/MauiProgram.cs
@@ -0,0 +1,39 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using ElVegetarianoFurio.Menu;
+using ElVegetarianoFurio.Profile;
+using MonkeyCache.FileStore;
+
+namespace ElVegetarianoFurio;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ Barrel.ApplicationId = "ElVegetarianoFurio";
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ fonts.AddFont("Font Awesome 5 Free-Solid-900.otf", "Fa-Solid");
+ fonts.AddFont("ShadowsIntoLight-Regular.ttf", "Shadows");
+ fonts.AddFont("Sofia-Regular.ttf", "Sofia");
+ });
+
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddSingleton();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ return builder.Build();
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
new file mode 100644
index 0000000..2d13767
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Category.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Category
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
new file mode 100644
index 0000000..b7dedd6
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
new file mode 100644
index 0000000..ac2fcdc
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryPage.xaml.cs
@@ -0,0 +1,56 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(CategoryId), nameof(CategoryId))]
+public partial class CategoryPage : ContentPage
+{
+ private readonly CategoryViewModel _viewModel;
+
+ public CategoryPage(CategoryViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int CategoryId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.CategoryId = CategoryId;
+ // Hack. CategoryId ist 0, wenn wir
+ // ber das Men der Shell zur Seite navigieren
+ if(CategoryId == 0)
+ {
+ _viewModel.CategoryId = GetCategoryIdFromRoute();
+ }
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+
+ private int GetCategoryIdFromRoute()
+ {
+ // Hack: Die Shell kann derzeit deklarativ noch keine
+ // Routenparameter bei der Navigation an eine Seite
+ // weitergeben. Deshalb ermitteln wir hier die Route
+ // der aktuellen Seite und geben hart codiert die ID
+ // zurck. Die Lsung ist nich schn und sollte
+ // umgestellt werden, sobald die Shell bei der
+ // deklarativen Navigation Argumente bergeben kann
+ var route = Shell.Current.CurrentState.Location
+ .OriginalString.Split("/").LastOrDefault();
+ return route switch
+ {
+ "ensaladas" => 1,
+ "sopas" => 2,
+ "tapas" => 3,
+ "principales" => 4,
+ "postres" => 5,
+ "bebidas" => 6,
+ _ => 0,
+ };
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
new file mode 100644
index 0000000..736ab91
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/CategoryViewModel.cs
@@ -0,0 +1,68 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+using System.Collections.ObjectModel;
+using System.Windows.Input;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class CategoryViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private readonly INavigationService _navigationService;
+ private Category _category;
+ private int _categoryId;
+
+ public CategoryViewModel(IDataService dataService,
+ INavigationService navigationService)
+ {
+ _dataService = dataService;
+ _navigationService = navigationService;
+ LoadDataCommand = new Command(async () => await LoadDataAsync());
+ NavigateToDishCommand = new Command(NavigateToDish);
+ }
+
+ public ICommand LoadDataCommand { get; }
+ public ICommand NavigateToDishCommand { get; }
+
+ public ObservableCollection Dishes { get; set; }
+ = new ObservableCollection();
+
+ public Category Category
+ {
+ get => _category;
+ set => SetProperty(ref _category, value);
+ }
+
+ public int CategoryId
+ {
+ get => _categoryId;
+ set => SetProperty(ref _categoryId, value);
+ }
+
+ private async Task LoadDataAsync()
+ {
+ Dishes.Clear();
+
+ Category = (await _dataService.GetCategoriesAsync())
+ .First(c => c.Id == CategoryId);
+ var dishes = await _dataService.GetDishesAsync(CategoryId);
+
+ foreach (var dish in dishes)
+ {
+ Dishes.Add(dish);
+ }
+ }
+
+ private async void NavigateToDish(Dish dish)
+ {
+ await _navigationService.GoToAsync($"{nameof(DishPage)}?DishId={dish.Id}");
+ }
+
+ public override async Task Initialize()
+ {
+ await LoadDataAsync();
+ await base.Initialize();
+ }
+}
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
new file mode 100644
index 0000000..ce1d48d
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/Dish.cs
@@ -0,0 +1,11 @@
+namespace ElVegetarianoFurio.Menu
+{
+ public class Dish
+ {
+ public int Id { get; set; }
+ public string Name { get; set; }
+ public string Description { get; set; }
+ public decimal Price { get; set; }
+ public int CategoryId { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
new file mode 100644
index 0000000..cccccf2
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
new file mode 100644
index 0000000..544f253
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishPage.xaml.cs
@@ -0,0 +1,27 @@
+namespace ElVegetarianoFurio.Menu;
+
+[QueryProperty(nameof(DishId), nameof(DishId))]
+public partial class DishPage : ContentPage
+{
+ private readonly DishViewModel _viewModel;
+
+ public DishPage(DishViewModel viewModel)
+ {
+ InitializeComponent();
+ BindingContext = _viewModel = viewModel;
+ }
+
+ public int DishId
+ {
+ get;
+ set;
+ }
+
+ protected override async void OnNavigatedTo(NavigatedToEventArgs args)
+ {
+ _viewModel.DishId = DishId;
+ await _viewModel.Initialize();
+ base.OnNavigatedTo(args);
+ }
+
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
new file mode 100644
index 0000000..f149c72
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Menu/DishViewModel.cs
@@ -0,0 +1,35 @@
+using ElVegetarianoFurio.Core;
+using ElVegetarianoFurio.Data;
+
+namespace ElVegetarianoFurio.Menu;
+
+public class DishViewModel : BaseViewModel
+{
+ private readonly IDataService _dataService;
+ private Dish _dish;
+ private int _dishId;
+
+ public Dish Dish
+ {
+ get => _dish;
+ set => SetProperty(ref _dish, value);
+ }
+
+ public DishViewModel(IDataService dataService)
+ {
+ _dataService = dataService;
+ }
+
+ public int DishId
+ {
+ get => _dishId;
+ set => SetProperty(ref _dishId, value);
+ }
+
+ public override async Task Initialize()
+ {
+ Dish = await _dataService.GetDishAsync(DishId);
+ await base.Initialize();
+ }
+}
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..d417720
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace ElVegetarianoFurio;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..cda2d65
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+
+namespace ElVegetarianoFurio;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..26cba44
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace ElVegetarianoFurio;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..4fcf4ee
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..b690b8f
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..fd599d4
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace ElVegetarianoFurio.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..ed272aa
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..9002b85
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace ElVegetarianoFurio;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..1b22262
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace ElVegetarianoFurio;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
new file mode 100644
index 0000000..079c1f0
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/IProfileService.cs
@@ -0,0 +1,9 @@
+using System.Threading.Tasks;
+
+namespace ElVegetarianoFurio.Profile;
+
+public interface IProfileService
+{
+ Task GetAsync();
+ Task SaveAsync(Profile profile);
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
new file mode 100644
index 0000000..6567b6a
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/Profile.cs
@@ -0,0 +1,14 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class Profile
+{
+ public string FullName { get; set; }
+
+ public string Street { get; set; }
+
+ public string Zip { get; set; }
+
+ public string City { get; set; }
+
+ public string Phone { get; set; }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
new file mode 100644
index 0000000..0baa045
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
new file mode 100644
index 0000000..af505a2
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfilePage.xaml.cs
@@ -0,0 +1,19 @@
+namespace ElVegetarianoFurio.Profile;
+
+public partial class ProfilePage : ContentPage
+{
+ private readonly ProfileViewModel _viewModel;
+
+ public ProfilePage(ProfileViewModel viewModel)
+ {
+ _viewModel = viewModel;
+ InitializeComponent();
+ BindingContext = _viewModel;
+ }
+
+ protected override async void OnAppearing()
+ {
+ base.OnAppearing();
+ await _viewModel.Initialize();
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
new file mode 100644
index 0000000..c29a330
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileService.cs
@@ -0,0 +1,17 @@
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileService : IProfileService
+{
+ private Profile _profile = new Profile();
+ public Task GetAsync()
+ {
+ return Task.FromResult(_profile);
+ }
+
+ public async Task SaveAsync(Profile profile)
+ {
+ _profile = profile;
+ await Task.Delay(3000); // Demo
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
new file mode 100644
index 0000000..8fc3ab6
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Profile/ProfileViewModel.cs
@@ -0,0 +1,106 @@
+using ElVegetarianoFurio.Core;
+
+namespace ElVegetarianoFurio.Profile;
+
+public class ProfileViewModel : BaseViewModel
+{
+ private readonly IProfileService _service;
+
+ private string _city = string.Empty;
+ private string _fullName = string.Empty;
+ private string _phone = string.Empty;
+ private string _street = string.Empty;
+ private string _zip = string.Empty;
+
+ public ProfileViewModel(IProfileService service)
+ {
+ _service = service;
+ Title = "Mein Profil";
+ SaveCommand = new Command(Save, CanSave);
+ }
+
+ private bool CanSave()
+ {
+ return !IsBusy;
+ }
+
+ public string FullName
+ {
+ get => _fullName;
+ set => SetProperty(ref _fullName, value);
+ }
+
+ public string Street
+ {
+ get => _street;
+ set => SetProperty(ref _street, value);
+ }
+
+ public string Zip
+ {
+ get => _zip;
+ set => SetProperty(ref _zip, value);
+ }
+
+ public string City
+ {
+ get => _city;
+ set => SetProperty(ref _city, value);
+ }
+
+ public string Phone
+ {
+ get => _phone;
+ set => SetProperty(ref _phone, value);
+ }
+
+ public Command SaveCommand { get; }
+
+ public override async Task Initialize()
+ {
+ try
+ {
+ IsBusy = true;
+ await base.Initialize();
+ var profile = await _service.GetAsync();
+ FullName = profile.FullName;
+ Street = profile.Street;
+ Zip = profile.Zip;
+ City = profile.City;
+ Phone = profile.Phone;
+ }
+ finally
+ {
+ await Task.Delay(10000); // Nur zu Demozwecken!
+ IsBusy = false;
+ }
+ }
+
+ private async void Save()
+ {
+ //if(IsBusy)
+ //{
+ // return;
+ //}
+ try
+ {
+ IsBusy = true;
+ SaveCommand.ChangeCanExecute();
+ var profile = new Profile
+ {
+ FullName = FullName,
+ Street = Street,
+ Zip = Zip,
+ City = City,
+ Phone = Phone
+ };
+
+ await _service.SaveAsync(profile);
+ }
+ finally
+ {
+ IsBusy = false;
+ SaveCommand.ChangeCanExecute();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf
new file mode 100644
index 0000000..8fb28d5
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Font Awesome 5 Free-Solid-900.otf differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf
new file mode 100644
index 0000000..b7bc796
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/ShadowsIntoLight-Regular.ttf differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf
new file mode 100644
index 0000000..aaee088
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Fonts/Sofia-Regular.ttf differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg
new file mode 100644
index 0000000..5287632
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category1.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg
new file mode 100644
index 0000000..d2e1756
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category2.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg
new file mode 100644
index 0000000..ad87a41
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category3.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg
new file mode 100644
index 0000000..4daa8f9
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category4.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg
new file mode 100644
index 0000000..cc079b2
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category5.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg
new file mode 100644
index 0000000..c6c5c3b
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/category6.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
new file mode 100644
index 0000000..572cad7
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/credits.txt
@@ -0,0 +1,111 @@
+category1.jpg
+https://unsplash.com/photos/IGfIGP5ONV0
+Unsplash / Anna Pelzer
+
+category2.jpg
+https://unsplash.com/photos/OMcrCX6wDpU
+Unsplash / Jade Aucamp
+
+category3.jpg
+https://pixabay.com/de/photos/creme-k%C3%A4se-tomate-sousse-chips-1503526/
+Pixybay / hamomdomingues
+
+category4.jpg
+https://www.pexels.com/photo/blur-bowl-close-up-cook-461326/
+Pexels / Pixabay
+
+category5.jpg
+https://pixabay.com/de/photos/eisbecher-speiseeis-eiscreme-2194070/
+Pixybay / silviarita
+
+category6.jpg
+https://mavl.io/photo/7331/summer-drink
+Mavl / picjumbo.com
+
+dish1.jpg
+https://unsplash.com/photos/MlPD-AzZYMg
+Unsplash / Louis Hansel
+
+dish2.jpg
+https://unsplash.com/photos/AiHJiRCwB3w
+Unsplash / Yoav Aziz
+
+dish3.jpg
+https://www.pexels.com/photo/appetizer-bowl-bread-breakfast-539451/
+Pexels / Foodie Factor
+
+dish4.jpg
+https://pixabay.com/de/photos/erbsensuppe-suppe-vorspeise-2786133/
+Pixabay / Ritae
+
+dish5.jpg
+https://pxhere.com/en/photo/758610
+pxhere
+
+dish6.jpg
+https://unsplash.com/photos/vzIgmhbEN9w
+Unsplash / Nacho Carretero Molero
+
+dish7.jpg
+https://pxhere.com/de/photo/459409
+pxhere
+
+dish8.jpg
+https://pxhere.com/es/photo/607309
+pxhere
+
+dish9.jpg
+https://pxhere.com/es/photo/529102
+pxhere
+
+dish10.jpg
+https://www.rawpixel.com/image/448047/free-photo-image-dip-mexican-cuisine-appetite
+rawpixel / Jakub Kapusnak
+
+dish11.jpg
+https://pixabay.com/de/photos/tjena-k%C3%BCche-chili-con-carne-reis-3175645/
+pixabay / TJENA
+
+dish12.jpg
+https://unsplash.com/photos/xsfX3AqLDKo
+Unsplash / Alexandra Golovac
+
+dish13.jpg
+https://pixabay.com/de/photos/burrito-tortilla-lebensmittel-4126116/
+pixabay / nevena1313
+
+dish14.jpg
+https://pixnio.com/food-and-drink/rice-food-dinner-lunch-dish-meal-vegetable-meat-delicious
+pixnio
+
+dish15.jpg
+https://pixabay.com/de/photos/empanadas-empanaditas-partei-macht-3410288/
+pixybay / Emersontc
+
+dish16.jpg
+https://pxhere.com/en/photo/863645
+pxhere
+
+
+dish17.jpg
+https://pixnio.com/flora-plants/fruits/fruit-salad-diet-food-nutrition-delicious-kiwi-sweet
+pixnio
+
+dish18.jpg
+https://pixabay.com/de/photos/churros-backen-cookies-dessert-2188871/
+pixabay / Daria-Yakovleva
+
+dish19.jpg
+https://pxhere.com/en/photo/1274085
+
+dish20.jpg
+https://pxhere.com/en/photo/1582781
+pxhere / rawpixel.com
+
+dish21.jpg
+https://unsplash.com/photos/p5EiqkBYIEE
+Unsplash / Francesca Hotchin
+
+dish22.jpg
+https://pxhere.com/en/photo/655302
+pxhere
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg
new file mode 100644
index 0000000..b4a8e6b
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish1.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg
new file mode 100644
index 0000000..af6ca2f
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish10.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg
new file mode 100644
index 0000000..be404cc
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish11.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg
new file mode 100644
index 0000000..83e883b
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish12.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg
new file mode 100644
index 0000000..60a51f3
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish13.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg
new file mode 100644
index 0000000..f833169
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish14.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg
new file mode 100644
index 0000000..a2a3be6
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish15.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg
new file mode 100644
index 0000000..b2f1d29
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish16.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg
new file mode 100644
index 0000000..a94addb
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish17.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg
new file mode 100644
index 0000000..e1b4bed
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish18.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg
new file mode 100644
index 0000000..eb5d8ab
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish19.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg
new file mode 100644
index 0000000..0106493
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish2.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg
new file mode 100644
index 0000000..72cbf4f
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish20.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg
new file mode 100644
index 0000000..6cfcda0
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish21.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg
new file mode 100644
index 0000000..5101c63
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish22.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg
new file mode 100644
index 0000000..33ed103
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish3.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg
new file mode 100644
index 0000000..96b9fb1
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish4.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg
new file mode 100644
index 0000000..e1d88a6
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish5.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg
new file mode 100644
index 0000000..fcd2757
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish6.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg
new file mode 100644
index 0000000..9eb85e9
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish7.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg
new file mode 100644
index 0000000..b6b9d0b
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish8.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg
new file mode 100644
index 0000000..f5f56a0
Binary files /dev/null and b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dish9.jpg differ
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
new file mode 100644
index 0000000..dfa107d
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Images/license.md
@@ -0,0 +1,59 @@
+All pictures are taken from the following sources:
+
+- Pexels
+- Pixabay
+- Pixnio
+- Pxhere
+- Rawpixl
+- Unsplash
+
+The licenses of those plattforms are:
+
+## Pexels
+https://www.pexels.com/photo-license/
+
+- All photos on Pexels are free to use.
+- Attribution is not required. Giving credit to the photographer or Pexels is not necessary but always appreciated.
+- You can modify the photos. Be creative and edit the photos as you like.
+entifiable people may not appear in a bad light or in a way that is offensive.
+- Don't sell unaltered copies of a photo, e.g. don't sell it as a stock photo, poster, print or on a physical product without adding any value.
+- Don't imply endorsement of your product by people or brands on the image.
+- Don't redistribute or sell the photos on other stock photo or wallpaper platforms.
+
+## Pixabay
+https://pixabay.com/de/service/terms/#license
+ilder und Videos auf Pixabay werden unter der Pixabay Lizenz mit den folgenden Bedingungen zur Verfügung gestellt. Durch die Pixabay Lizenz erhältst Du ein unwiderrufliches, weltweites, nicht exklusives und gebührenfreies Recht, die Bilder und Videos für kommerzielle und nicht kommerzielle Zwecke zu verwenden, herunterzuladen, zu kopieren und zu verändern. Eine Nennung des Bildautors bzw. von Pixabay ist nicht erforderlich, wir wissen jedoch eine freiwillige Quellenangabe zu schätzen.
+
+Die Pixabay-Lizenz gestattet nicht:
+
+ den Verkauf oder Vertrieb von Bildern oder Videos in digitaler Form, insbesondere als Stockfotos oder digitale Wallpaper;
+ den Verkauf oder Vertrieb von Bildern oder Videos z.B. als Poster, Digitaldrucke oder physische Produkte, ohne zusätzliche Elemente hinzuzufügen oder anderweitig einen Mehrwert zu schaffen;
+ die Darstellung von identifizierbaren Personen auf beleidigende, pornografische, obszöne, unmoralische, diffamierende oder verleumderische Weise; oder
+ die Suggestion, dass abgebildete Personen, Marken, Organisationen, etc. bestimmte Produkte oder Dienstleistungen befürworten oder billigen, es sei denn es wurde eine Genehmigung dazu erteilt.
+
+Beachte bitte, dass alle Inhalte auf Pixabay zwar für kommerzielle und nicht-kommerzielle Zwecke frei verwendbar sind, gezeigte Elemente in den Bildern und Videos, wie identifizierbare Personen, Logos und Marken, jedoch zusätzlichen Urheberrechten, Eigentumsrechten, Personenrechten, Markenrechten usw. unterliegen können. Die Zustimmung eines Dritten oder die Lizenz dieser Rechte können insbesondere für kommerzielle Anwendungen erforderlich sein. Pixabay garantiert nicht, dass solche Zustimmungen oder Lizenzen eingeholt wurden, und lehnt ausdrücklich jegliche Haftung in dieser Hinsicht ab.
+
+## Pixnio
+https://pixnio.com/de/
+https://pixnio.com/public-domain-definition
+Hochwertige urheberrechts-freundliche Bilder, urheberrechtsfreie Bilder und Bilder ohne Beschränkung für deren Verwendung. Explizit in der Public Domain platzierte Bilder, keine Rechte vorbehalten. Public Domain Bilder können für beliebige Zwecke genutzt werden, nutzen Sie diese frei für persönliche oder kommerzielle Nutzung.
+
+## Pxhere
+https://pxhere.com/de/license
+
+ It's hard to understand complex licenses that is why all photos on PxHere are licensed under the Creative Commons Zero (CC0) license. This means the pictures are completely free to be used for any legal purpose.
+ The pictures are free for personal and even for commercial use.
+ You can modify, copy and distribute the photos.
+ All without asking for permission or setting a link to the source. So, attribution is not required.
+ The only restriction is that identifiable people may not appear in a bad light or in a way that they may find offensive, unless they give their consent.
+ The CC0 license was released by the non-profit organization Creative Commons (CC). Get more information about Creative Commons images and the license on the official license page.
+
+## Rawpixl
+https://www.rawpixel.com/services/image-licenses
+
+## Unsplash
+https://unsplash.com/license
+All photos published on Unsplash can be used for free. You can use them for commercial and noncommercial purposes. You do not need to ask permission from or provide credit to the photographer or Unsplash, although it is appreciated when possible.
+
+More precisely, Unsplash grants you an irrevocable, nonexclusive, worldwide copyright license to download, copy, modify, distribute, perform, and use photos from Unsplash for free, including for commercial purposes, without permission from or attributing the photographer or Unsplash. This license does not include the right to compile photos from Unsplash to replicate a similar or competing service.
+
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml
new file mode 100644
index 0000000..f551fef
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs
new file mode 100644
index 0000000..a0dd304
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/AppStyles.xaml.cs
@@ -0,0 +1,9 @@
+namespace ElVegetarianoFurio.Resources.Styles;
+
+public partial class AppStyles : ResourceDictionary
+{
+ public AppStyles()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap14/ElVegetarianoFurio/ElVegetarianoFurio/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample.sln b/Kap14/WebserviceSample/WebserviceSample.sln
new file mode 100644
index 0000000..9db5340
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample.sln
@@ -0,0 +1,27 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31611.283
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WebserviceSample", "WebserviceSample\WebserviceSample.csproj", "{AD965A0B-173C-479D-B43F-30446FE311E9}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Release|Any CPU.Build.0 = Release|Any CPU
+ {AD965A0B-173C-479D-B43F-30446FE311E9}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
+ EndGlobalSection
+EndGlobal
diff --git a/Kap14/WebserviceSample/WebserviceSample/App.xaml b/Kap14/WebserviceSample/WebserviceSample/App.xaml
new file mode 100644
index 0000000..0dc1e92
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/App.xaml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/App.xaml.cs b/Kap14/WebserviceSample/WebserviceSample/App.xaml.cs
new file mode 100644
index 0000000..fc6a594
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/App.xaml.cs
@@ -0,0 +1,11 @@
+namespace WebserviceSample;
+
+public partial class App : Application
+{
+ public App()
+ {
+ InitializeComponent();
+
+ MainPage = new AppShell();
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml b/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml
new file mode 100644
index 0000000..81ed8f4
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml.cs b/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml.cs
new file mode 100644
index 0000000..1783f03
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/AppShell.xaml.cs
@@ -0,0 +1,14 @@
+using WebserviceSample.Views;
+
+namespace WebserviceSample;
+
+public partial class AppShell : Shell
+{
+ public AppShell()
+ {
+ InitializeComponent();
+ Routing.RegisterRoute(nameof(SpeakerDetailPage), typeof(SpeakerDetailPage));
+ Routing.RegisterRoute(nameof(NewSpeakerPage), typeof(NewSpeakerPage));
+
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml b/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml
new file mode 100644
index 0000000..c89dbc4
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml.cs b/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml.cs
new file mode 100644
index 0000000..11ec7bb
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/MainPage.xaml.cs
@@ -0,0 +1,24 @@
+namespace WebserviceSample;
+
+public partial class MainPage : ContentPage
+{
+ int count = 0;
+
+ public MainPage()
+ {
+ InitializeComponent();
+ }
+
+ private void OnCounterClicked(object sender, EventArgs e)
+ {
+ count++;
+
+ if (count == 1)
+ CounterBtn.Text = $"Clicked {count} time";
+ else
+ CounterBtn.Text = $"Clicked {count} times";
+
+ SemanticScreenReader.Announce(CounterBtn.Text);
+ }
+}
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/MauiProgram.cs b/Kap14/WebserviceSample/WebserviceSample/MauiProgram.cs
new file mode 100644
index 0000000..7cca436
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/MauiProgram.cs
@@ -0,0 +1,35 @@
+using Microsoft.Extensions.DependencyInjection;
+using MonkeyCache.FileStore;
+using WebserviceSample.Models;
+using WebserviceSample.Services;
+using WebserviceSample.ViewModels;
+using WebserviceSample.Views;
+
+namespace WebserviceSample;
+
+public static class MauiProgram
+{
+ public static MauiApp CreateMauiApp()
+ {
+ var builder = MauiApp.CreateBuilder();
+ builder
+ .UseMauiApp()
+ .ConfigureFonts(fonts =>
+ {
+ fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
+ fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
+ });
+
+ builder.Services.AddSingleton, SpeakerDataStore>();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+ builder.Services.AddTransient();
+
+ Barrel.ApplicationId = "WebserviceSample Demo App";
+
+ return builder.Build();
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Models/Speaker.cs b/Kap14/WebserviceSample/WebserviceSample/Models/Speaker.cs
new file mode 100644
index 0000000..e616ad0
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Models/Speaker.cs
@@ -0,0 +1,13 @@
+
+using System.Text.Json.Serialization;
+
+namespace WebserviceSample.Models;
+
+public class Speaker
+{
+ public int Id { get; set; }
+ [JsonPropertyName("name")]
+ public string FullName { get; set; }
+ public string Company { get; set; }
+ public string Bio { get; set; }
+}
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/AndroidManifest.xml b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/AndroidManifest.xml
new file mode 100644
index 0000000..e9937ad
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainActivity.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainActivity.cs
new file mode 100644
index 0000000..daf8ccc
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainActivity.cs
@@ -0,0 +1,10 @@
+using Android.App;
+using Android.Content.PM;
+using Android.OS;
+
+namespace WebserviceSample;
+
+[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
+public class MainActivity : MauiAppCompatActivity
+{
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainApplication.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainApplication.cs
new file mode 100644
index 0000000..c2b6a94
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/MainApplication.cs
@@ -0,0 +1,15 @@
+using Android.App;
+using Android.Runtime;
+[assembly: UsesPermission(Android.Manifest.Permission.AccessNetworkState)]
+namespace WebserviceSample;
+
+[Application]
+public class MainApplication : MauiApplication
+{
+ public MainApplication(IntPtr handle, JniHandleOwnership ownership)
+ : base(handle, ownership)
+ {
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/Resources/values/colors.xml b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/Resources/values/colors.xml
new file mode 100644
index 0000000..c04d749
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Android/Resources/values/colors.xml
@@ -0,0 +1,6 @@
+
+
+ #512BD4
+ #2B0B98
+ #2B0B98
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/AppDelegate.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/AppDelegate.cs
new file mode 100644
index 0000000..eebe0b0
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace WebserviceSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Info.plist b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Info.plist
new file mode 100644
index 0000000..c96dd0a
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Info.plist
@@ -0,0 +1,30 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Program.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Program.cs
new file mode 100644
index 0000000..eea0808
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/MacCatalyst/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace WebserviceSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/Main.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/Main.cs
new file mode 100644
index 0000000..f83953c
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using Microsoft.Maui;
+using Microsoft.Maui.Hosting;
+
+namespace WebserviceSample;
+
+class Program : MauiApplication
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+
+ static void Main(string[] args)
+ {
+ var app = new Program();
+ app.Run(args);
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/tizen-manifest.xml b/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/tizen-manifest.xml
new file mode 100644
index 0000000..499a2b9
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Tizen/tizen-manifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ maui-appicon-placeholder
+
+
+
+
+ http://tizen.org/privilege/internet
+
+
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml
new file mode 100644
index 0000000..5b562c7
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml
@@ -0,0 +1,8 @@
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml.cs
new file mode 100644
index 0000000..b3881cc
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/App.xaml.cs
@@ -0,0 +1,24 @@
+using Microsoft.UI.Xaml;
+
+// To learn more about WinUI, the WinUI project structure,
+// and more about our project templates, see: http://aka.ms/winui-project-info.
+
+namespace WebserviceSample.WinUI;
+
+///
+/// Provides application-specific behavior to supplement the default Application class.
+///
+public partial class App : MauiWinUIApplication
+{
+ ///
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ ///
+ public App()
+ {
+ this.InitializeComponent();
+ }
+
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/Package.appxmanifest b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/Package.appxmanifest
new file mode 100644
index 0000000..2bcb11e
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/Package.appxmanifest
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+ $placeholder$
+ User Name
+ $placeholder$.png
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/app.manifest b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/app.manifest
new file mode 100644
index 0000000..e90f77d
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/Windows/app.manifest
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+ true/PM
+ PerMonitorV2, PerMonitor
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/AppDelegate.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/AppDelegate.cs
new file mode 100644
index 0000000..eebe0b0
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/AppDelegate.cs
@@ -0,0 +1,9 @@
+using Foundation;
+
+namespace WebserviceSample;
+
+[Register("AppDelegate")]
+public class AppDelegate : MauiUIApplicationDelegate
+{
+ protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Info.plist b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Info.plist
new file mode 100644
index 0000000..0004a4f
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Info.plist
@@ -0,0 +1,32 @@
+
+
+
+
+ LSRequiresIPhoneOS
+
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UIRequiredDeviceCapabilities
+
+ arm64
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/appicon.appiconset
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Program.cs b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Program.cs
new file mode 100644
index 0000000..eea0808
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Platforms/iOS/Program.cs
@@ -0,0 +1,15 @@
+using ObjCRuntime;
+using UIKit;
+
+namespace WebserviceSample;
+
+public class Program
+{
+ // This is the main entry point of the application.
+ static void Main(string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main(args, null, typeof(AppDelegate));
+ }
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Properties/launchSettings.json b/Kap14/WebserviceSample/WebserviceSample/Properties/launchSettings.json
new file mode 100644
index 0000000..edf8aad
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Properties/launchSettings.json
@@ -0,0 +1,8 @@
+{
+ "profiles": {
+ "Windows Machine": {
+ "commandName": "MsixPackage",
+ "nativeDebugging": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appicon.svg b/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appicon.svg
new file mode 100644
index 0000000..9d63b65
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appicon.svg
@@ -0,0 +1,4 @@
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appiconfg.svg b/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appiconfg.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/AppIcon/appiconfg.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Regular.ttf b/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Regular.ttf
new file mode 100644
index 0000000..6cbaf4b
Binary files /dev/null and b/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Regular.ttf differ
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Semibold.ttf b/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Semibold.ttf
new file mode 100644
index 0000000..554d68a
Binary files /dev/null and b/Kap14/WebserviceSample/WebserviceSample/Resources/Fonts/OpenSans-Semibold.ttf differ
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Images/dotnet_bot.svg b/Kap14/WebserviceSample/WebserviceSample/Resources/Images/dotnet_bot.svg
new file mode 100644
index 0000000..abfaff2
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/Images/dotnet_bot.svg
@@ -0,0 +1,93 @@
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Raw/AboutAssets.txt b/Kap14/WebserviceSample/WebserviceSample/Resources/Raw/AboutAssets.txt
new file mode 100644
index 0000000..15d6244
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/Raw/AboutAssets.txt
@@ -0,0 +1,15 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories). Deployment of the asset to your application
+is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
+
+
+
+These files will be deployed with you package and will be accessible using Essentials:
+
+ async Task LoadMauiAsset()
+ {
+ using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
+ using var reader = new StreamReader(stream);
+
+ var contents = reader.ReadToEnd();
+ }
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Splash/splash.svg b/Kap14/WebserviceSample/WebserviceSample/Resources/Splash/splash.svg
new file mode 100644
index 0000000..21dfb25
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/Splash/splash.svg
@@ -0,0 +1,8 @@
+
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Colors.xaml b/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Colors.xaml
new file mode 100644
index 0000000..245758b
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Colors.xaml
@@ -0,0 +1,44 @@
+
+
+
+
+ #512BD4
+ #DFD8F7
+ #2B0B98
+ White
+ Black
+ #E1E1E1
+ #C8C8C8
+ #ACACAC
+ #919191
+ #6E6E6E
+ #404040
+ #212121
+ #141414
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #F7B548
+ #FFD590
+ #FFE5B9
+ #28C2D1
+ #7BDDEF
+ #C3F2F4
+ #3E8EED
+ #72ACF1
+ #A7CBF6
+
+
\ No newline at end of file
diff --git a/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Styles.xaml b/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Styles.xaml
new file mode 100644
index 0000000..1ec9d55
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Resources/Styles/Styles.xaml
@@ -0,0 +1,384 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Kap14/WebserviceSample/WebserviceSample/Services/IDataStore.cs b/Kap14/WebserviceSample/WebserviceSample/Services/IDataStore.cs
new file mode 100644
index 0000000..e892d44
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Services/IDataStore.cs
@@ -0,0 +1,10 @@
+namespace WebserviceSample.Services;
+
+public interface IDataStore
+{
+ Task AddItemAsync(T item);
+ Task UpdateItemAsync(T item);
+ Task DeleteItemAsync(int id);
+ Task GetItemAsync(int id);
+ Task> GetItemsAsync(bool forceRefresh = false);
+}
diff --git a/Kap14/WebserviceSample/WebserviceSample/Services/SpeakerDataStore.cs b/Kap14/WebserviceSample/WebserviceSample/Services/SpeakerDataStore.cs
new file mode 100644
index 0000000..57dbacb
--- /dev/null
+++ b/Kap14/WebserviceSample/WebserviceSample/Services/SpeakerDataStore.cs
@@ -0,0 +1,76 @@
+using System.Text;
+using System.Text.Json;
+using MonkeyCache.FileStore;
+using WebserviceSample.Models;
+
+namespace WebserviceSample.Services;
+
+public class SpeakerDataStore : IDataStore
+{
+ private static readonly HttpClient _client = new HttpClient
+ {
+ BaseAddress = new Uri(
+ "https://my-json-server.typicode.com/AndreKraemer/ConferenceAppDemoData/")
+ };
+
+ private static JsonSerializerOptions _serializerOptions
+ = new JsonSerializerOptions
+ {
+ PropertyNameCaseInsensitive = true,
+ PropertyNamingPolicy = JsonNamingPolicy.CamelCase
+ };
+
+ public async Task AddItemAsync(Speaker speaker)
+ {
+ var json = JsonSerializer.Serialize(speaker, _serializerOptions);
+ var content = new StringContent(json, Encoding.UTF8, "application/json");
+ var result = await _client.PostAsync("speakers", content);
+ return result.IsSuccessStatusCode;
+ }
+
+ public async Task UpdateItemAsync(Speaker speaker)
+ {
+ var json = JsonSerializer.Serialize(speaker, _serializerOptions);
+ var content = new StringContent(json, Encoding.UTF8, "application/json");
+ var result = await _client.PutAsync($"speakers/{speaker.Id}", content);
+ return result.IsSuccessStatusCode;
+ }
+
+ public async Task DeleteItemAsync(int id)
+ {
+ var result = await _client.DeleteAsync($"speakers/{id}");
+ return result.IsSuccessStatusCode;
+ }
+
+ public async Task GetItemAsync(int id)
+ {
+ var json = await _client.GetStringAsync($"speakers/{id}");
+ var speaker = JsonSerializer.Deserialize(json, _serializerOptions);
+ return speaker;
+ }
+
+ public async Task> GetItemsAsync(bool forceRefresh = false)
+ {
+ // Wenn keine Internetverbindung besteht gecachte Daten zurückgeben,
+ // auch wenn diese bereits abgelaufen sind.
+ if (Connectivity.NetworkAccess != NetworkAccess.Internet)
+ {
+ return Barrel.Current.Get>("speakers") ?? Array.Empty