punker76 / MahApps.Metro.SimpleChildWindow

A simple child window for MahApps.Metro
MIT License
374 stars 55 forks source link

InvalidOperationException when using from different threads #47

Closed pchinery closed 7 years ago

pchinery commented 7 years ago

We have a scenario, where we have two main MetroWindows that can both show overlays. To show the overlay, we create a new instance of ChildWindow in the respective thread. When setting the content property the second time (first time in second thread), we receive an InvalidOperationException, stating that some SolidColorBrush was not frozen and may not be used across threads.

I have create a reproduction repo here: https://github.com/pchinery/simplechildwindow-bugreport

You can start the application and follow the instructions on the screen ;-) (click a button to start the second thread and click a button in both windows to create the overlay)

If you have any questions or comments, please let me know

punker76 commented 7 years ago

Fixed in v1.3.1