[FancyZones Editor] Prevent opening content dialog twice (#13621)

This commit is contained in:
Seraphima Zykova
2021-10-05 12:55:23 +03:00
committed by GitHub
parent cf2ec690db
commit bec0dc3c0b

View File

@@ -161,6 +161,12 @@ namespace FancyZonesEditor
private async void NewLayoutButton_Click(object sender, RoutedEventArgs e)
{
if (_openedDialog != null)
{
// another dialog already opened
return;
}
string defaultNamePrefix = FancyZonesEditor.Properties.Resources.Default_Custom_Layout_Name;
int maxCustomIndex = 0;
foreach (LayoutModel customModel in MainWindowSettingsModel.CustomModels)