diff --git a/POC/WpfApp1.sln b/POC/WpfApp1.sln
new file mode 100644
index 0000000..cc8fa16
--- /dev/null
+++ b/POC/WpfApp1.sln
@@ -0,0 +1,25 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.7.34031.279
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WpfApp1", "WpfApp1\WpfApp1.csproj", "{5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {C7CDF771-EEA9-421B-854E-7D1CC90BA16A}
+ EndGlobalSection
+EndGlobal
diff --git a/POC/WpfApp1/App.config b/POC/WpfApp1/App.config
new file mode 100644
index 0000000..7c4b745
--- /dev/null
+++ b/POC/WpfApp1/App.config
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/POC/WpfApp1/App.xaml b/POC/WpfApp1/App.xaml
new file mode 100644
index 0000000..b84951b
--- /dev/null
+++ b/POC/WpfApp1/App.xaml
@@ -0,0 +1,10 @@
+
+
+
+
+
diff --git a/POC/WpfApp1/App.xaml.cs b/POC/WpfApp1/App.xaml.cs
new file mode 100644
index 0000000..38f5edd
--- /dev/null
+++ b/POC/WpfApp1/App.xaml.cs
@@ -0,0 +1,9 @@
+namespace WpfApp1
+{
+ ///
+ /// Interaction logic for App.xaml
+ ///
+ public partial class App
+ {
+ }
+}
diff --git a/POC/WpfApp1/DialogFrame.xaml b/POC/WpfApp1/DialogFrame.xaml
new file mode 100644
index 0000000..fa2ba95
--- /dev/null
+++ b/POC/WpfApp1/DialogFrame.xaml
@@ -0,0 +1,71 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/POC/WpfApp1/DialogFrame.xaml.cs b/POC/WpfApp1/DialogFrame.xaml.cs
new file mode 100644
index 0000000..99a3dda
--- /dev/null
+++ b/POC/WpfApp1/DialogFrame.xaml.cs
@@ -0,0 +1,76 @@
+using System.Windows.Controls;
+using System.Windows.Input;
+
+namespace WpfApp1
+{
+ using System.Windows;
+
+ ///
+ /// Interaction logic for DialogFrame.xaml
+ ///
+ public partial class DialogFrame
+ {
+ private Point? _mousePointOnClick;
+
+ public DialogFrame(string title, string message)
+ {
+ InitializeComponent();
+ this.TitleBlock.Text = title;
+ this.MessageBlock.Text = message;
+ SetMouseStatus();
+ }
+
+ private void CloseDialog_OnClick(object sender, RoutedEventArgs e)
+ {
+ DialogService.Instance.Remove(this);
+ }
+
+ private void NewDialog_OnClick(object sender, RoutedEventArgs e)
+ {
+ DialogService.Instance.Add(
+ new DialogFrame("Child", $"Child dialog {DialogService.Instance.Dialogs.Count}")
+ );
+ }
+
+ private void Border_OnMouseDown(object sender, MouseButtonEventArgs e)
+ {
+ var thisPosition = e.GetPosition(this);
+ _mousePointOnClick = new Point(
+ thisPosition.X - BorderTransform.X,
+ thisPosition.Y - BorderTransform.Y
+ );
+ SetMouseStatus();
+ }
+
+ private void Border_OnMouseMove(object sender, MouseEventArgs e)
+ {
+ if (e.LeftButton == MouseButtonState.Pressed && _mousePointOnClick is { } pointOnClick)
+ {
+ var pos = e.GetPosition(this);
+ BorderTransform.X = pos.X - pointOnClick.X;
+ BorderTransform.Y = pos.Y - pointOnClick.Y;
+ }
+ SetMouseStatus();
+ }
+
+ private void Border_OnMouseUp(object sender, MouseButtonEventArgs e)
+ {
+ _mousePointOnClick = null;
+ SetMouseStatus();
+ }
+
+ private void SetMouseStatus()
+ {
+ MouseStatus.Text =
+ $"""PointOnClick:"{(_mousePointOnClick?.ToString() ?? "")}", BorderTransform:"{BorderTransform.X:F1}:{BorderTransform.Y:F1}" """;
+ }
+
+ private void DialogFrame_OnKeyDown(object sender, KeyEventArgs e)
+ {
+ if (e.Key == Key.Escape)
+ {
+ DialogService.Instance.Remove(this);
+ }
+ }
+ }
+}
diff --git a/POC/WpfApp1/DialogService.cs b/POC/WpfApp1/DialogService.cs
new file mode 100644
index 0000000..ae81a66
--- /dev/null
+++ b/POC/WpfApp1/DialogService.cs
@@ -0,0 +1,31 @@
+namespace WpfApp1
+{
+ using System;
+ using System.Collections.ObjectModel;
+ using System.Windows.Controls;
+
+ public class DialogService
+ {
+ private static readonly Lazy LazyInstance = new(() => new DialogService());
+ private readonly ObservableCollection _dialogs = new();
+
+ public DialogService()
+ {
+ Dialogs = new ReadOnlyObservableCollection(_dialogs);
+ }
+
+ public static DialogService Instance => LazyInstance.Value;
+
+ public ReadOnlyObservableCollection Dialogs { get; }
+
+ public void Add(UserControl userControl)
+ {
+ _dialogs.Add(userControl);
+ }
+
+ public void Remove(UserControl userControl)
+ {
+ _dialogs.Remove(userControl);
+ }
+ }
+}
diff --git a/POC/WpfApp1/MainWindow.xaml b/POC/WpfApp1/MainWindow.xaml
new file mode 100644
index 0000000..aea147c
--- /dev/null
+++ b/POC/WpfApp1/MainWindow.xaml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/POC/WpfApp1/MainWindow.xaml.cs b/POC/WpfApp1/MainWindow.xaml.cs
new file mode 100644
index 0000000..cd31f5d
--- /dev/null
+++ b/POC/WpfApp1/MainWindow.xaml.cs
@@ -0,0 +1,20 @@
+namespace WpfApp1
+{
+ using System.Windows;
+
+ ///
+ /// Interaction logic for MainWindow.xaml
+ ///
+ public partial class MainWindow
+ {
+ public MainWindow()
+ {
+ InitializeComponent();
+ }
+
+ private void ButtonBase_OnClick(object sender, RoutedEventArgs e)
+ {
+ MessageBox.Show($"This is a message box. Sent by a {sender.GetType().Name}.", this.Title, MessageBoxButton.OK, MessageBoxImage.Information, MessageBoxResult.OK);
+ }
+ }
+}
diff --git a/POC/WpfApp1/MainWindowViewModel.cs b/POC/WpfApp1/MainWindowViewModel.cs
new file mode 100644
index 0000000..fa2bbc2
--- /dev/null
+++ b/POC/WpfApp1/MainWindowViewModel.cs
@@ -0,0 +1,73 @@
+using System.IO;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+
+namespace WpfApp1
+{
+ using System;
+ using System.Collections.ObjectModel;
+ using System.Linq;
+ using System.Windows.Controls;
+
+ using CommunityToolkit.Mvvm.ComponentModel;
+ using CommunityToolkit.Mvvm.Input;
+
+ public class MainWindowViewModel : ObservableObject
+ {
+ private RelayCommand _openDialogCommand;
+ private IRelayCommand _testMultiStreamingCommand;
+
+ public IRelayCommand OpenDialogCommand =>
+ _openDialogCommand ??= new RelayCommand(OpenDialog);
+
+ public ReadOnlyObservableCollection Dialogs => DialogService.Instance.Dialogs;
+
+ public IRelayCommand TestMultiStreamingCommand =>
+ _testMultiStreamingCommand ??= new AsyncRelayCommand(TestMultiStreaming);
+
+ private async Task TestMultiStreaming()
+ {
+ try
+ {
+ const string path = @"C:\Users\Holger\Desktop\WpfApp1.txt";
+ using var openFile1 = new FileStream(
+ path,
+ FileMode.Create,
+ FileAccess.Write,
+ FileShare.ReadWrite
+ );
+ using var writer1 = new StreamWriter(openFile1, Encoding.Unicode);
+ await writer1.WriteLineAsync($"{DateTime.Now:O} Hello from Writer 1");
+ await writer1.FlushAsync();
+ using var openFile2 = new FileStream(
+ path,
+ FileMode.Open,
+ FileAccess.Read,
+ FileShare.ReadWrite
+ );
+ using var reader = new StreamReader(openFile2, Encoding.Unicode);
+ var content = await reader.ReadToEndAsync();
+ MessageBox.Show(content);
+ }
+ catch (Exception e)
+ {
+ MessageBox.Show(e.Message);
+ }
+ }
+
+ private static void OpenDialog()
+ {
+ DialogService.Instance.Add(
+ new DialogFrame(
+ "Main dialog",
+ "Main dialog"
+ + string.Join(
+ Environment.NewLine,
+ Enumerable.Repeat(Environment.OSVersion, 10)
+ )
+ )
+ );
+ }
+ }
+}
diff --git a/POC/WpfApp1/Properties/AssemblyInfo.cs b/POC/WpfApp1/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..2e4be22
--- /dev/null
+++ b/POC/WpfApp1/Properties/AssemblyInfo.cs
@@ -0,0 +1,52 @@
+using System.Reflection;
+using System.Runtime.InteropServices;
+using System.Windows;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("WpfApp1")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("ise GmbH")]
+[assembly: AssemblyProduct("WpfApp1")]
+[assembly: AssemblyCopyright("Copyright © ise GmbH 2023")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+//In order to begin building localizable applications, set
+//CultureYouAreCodingWith in your .csproj file
+//inside a . For example, if you are using US english
+//in your source files, set the to en-US. Then uncomment
+//the NeutralResourceLanguage attribute below. Update the "en-US" in
+//the line below to match the UICulture setting in the project file.
+
+//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
+
+
+[assembly: ThemeInfo(
+ ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
+ //(used if a resource is not found in the page,
+ // or application resource dictionaries)
+ ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
+//(used if a resource is not found in the page,
+// app, or any theme specific resource dictionaries)
+)]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/POC/WpfApp1/Properties/Resources.Designer.cs b/POC/WpfApp1/Properties/Resources.Designer.cs
new file mode 100644
index 0000000..e015690
--- /dev/null
+++ b/POC/WpfApp1/Properties/Resources.Designer.cs
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.42000
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace WpfApp1.Properties
+{
+
+
+ ///
+ /// A strongly-typed resource class, for looking up localized strings, etc.
+ ///
+ // This class was auto-generated by the StronglyTypedResourceBuilder
+ // class via a tool like ResGen or Visual Studio.
+ // To add or remove a member, edit your .ResX file then rerun ResGen
+ // with the /str option, or rebuild your VS project.
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ internal class Resources
+ {
+
+ private static global::System.Resources.ResourceManager resourceMan;
+
+ private static global::System.Globalization.CultureInfo resourceCulture;
+
+ [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+ internal Resources()
+ {
+ }
+
+ ///
+ /// Returns the cached ResourceManager instance used by this class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Resources.ResourceManager ResourceManager
+ {
+ get
+ {
+ if ((resourceMan == null))
+ {
+ global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WpfApp1.Properties.Resources", typeof(Resources).Assembly);
+ resourceMan = temp;
+ }
+ return resourceMan;
+ }
+ }
+
+ ///
+ /// Overrides the current thread's CurrentUICulture property for all
+ /// resource lookups using this strongly typed resource class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Globalization.CultureInfo Culture
+ {
+ get
+ {
+ return resourceCulture;
+ }
+ set
+ {
+ resourceCulture = value;
+ }
+ }
+ }
+}
diff --git a/POC/WpfApp1/Properties/Resources.resx b/POC/WpfApp1/Properties/Resources.resx
new file mode 100644
index 0000000..af7dbeb
--- /dev/null
+++ b/POC/WpfApp1/Properties/Resources.resx
@@ -0,0 +1,117 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/POC/WpfApp1/Properties/Settings.Designer.cs b/POC/WpfApp1/Properties/Settings.Designer.cs
new file mode 100644
index 0000000..6735d52
--- /dev/null
+++ b/POC/WpfApp1/Properties/Settings.Designer.cs
@@ -0,0 +1,30 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.42000
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace WpfApp1.Properties
+{
+
+
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
+ internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
+ {
+
+ private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
+
+ public static Settings Default
+ {
+ get
+ {
+ return defaultInstance;
+ }
+ }
+ }
+}
diff --git a/POC/WpfApp1/Properties/Settings.settings b/POC/WpfApp1/Properties/Settings.settings
new file mode 100644
index 0000000..033d7a5
--- /dev/null
+++ b/POC/WpfApp1/Properties/Settings.settings
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/POC/WpfApp1/WpfApp1.csproj b/POC/WpfApp1/WpfApp1.csproj
new file mode 100644
index 0000000..337ca56
--- /dev/null
+++ b/POC/WpfApp1/WpfApp1.csproj
@@ -0,0 +1,118 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {5E84BEC0-370F-4F3E-8B59-E37EFD3E4438}
+ WinExe
+ WpfApp1
+ WpfApp1
+ v4.8
+ 512
+ {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ 4
+ true
+ true
+
+
+
+
+ AnyCPU
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+ latest
+
+
+ AnyCPU
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+ latest
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 4.0
+
+
+
+
+
+
+
+ MSBuild:Compile
+ Designer
+
+
+ Designer
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+ Designer
+
+
+ App.xaml
+ Code
+
+
+ DialogFrame.xaml
+
+
+
+ MainWindow.xaml
+ Code
+
+
+
+
+
+ Code
+
+
+ True
+ True
+ Resources.resx
+
+
+ True
+ Settings.settings
+ True
+
+
+ ResXFileCodeGenerator
+ Resources.Designer.cs
+
+
+ SettingsSingleFileGenerator
+ Settings.Designer.cs
+
+
+
+
+
+
+
+ 8.2.1
+
+
+
+
\ No newline at end of file