MahApps.Metro.SimpleChildWindow icon indicating copy to clipboard operation
MahApps.Metro.SimpleChildWindow copied to clipboard

IsAnyDialogOpen (MahApps) not working for child windows

Open punker76 opened this issue 6 years ago • 1 comments

Imported from https://github.com/MahApps/MahApps.Metro/issues/3223

IsAnyDialogOpen property is set to false although a child window is shown using the ShowChildWindowAsync by the MahApps.Metro.SimpleChildWindow extension

What steps will reproduce this issue?

var result = await this.ShowChildWindowAsync<bool>(new UserControl { IsModal = false });

// somewhere else in code

if (this.IsAnyDialogOpen == false)
 MessageBox.Show("you shouldn' see this);

Expected outcome

Property should return TRUE if there is a child window shown. Otherwise there should be another property for it.

Environment

  • MahApps.Metro 1.6.1
  • MahApps.Metro.SimpleChildWindow 1.5
  • Windows OS Win10
  • Visual Studio 2017
  • .NET Framework 4.7

punker76 avatar Apr 21 '18 20:04 punker76

Is there any possibility to fix this issue? How do I know if any dialog is open? Background Information: I watch ESC-Keypresses to close my window and would like to ignore this if any ChildWindow is open. Thanks!

thbiela avatar Sep 02 '18 09:09 thbiela