Skip to content

Commit 7ff6afb

Browse files
authored
When host is TopMost set popup Topmost (#3166)
1 parent 6b5aaa6 commit 7ff6afb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

MaterialDesignThemes.Wpf/PopupEx.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ private void PopupEx_Loaded(object? sender, RoutedEventArgs e)
9292
}
9393

9494
private void PopupEx_Opened(object? sender, EventArgs e)
95-
=> SetTopmostState(_hostWindow?.IsActive ?? true);
95+
=> SetTopmostState(_hostWindow is null || _hostWindow is { IsActive: true } || _hostWindow is { Topmost: true });
9696

9797
private void HostWindow_Activated(object? sender, EventArgs e)
9898
=> SetTopmostState(true);

0 commit comments

Comments
 (0)