Skip to content

Nested dialog not visible after closing and reopening parent dialog #3735

Open

Description

@Yoooi0

Bug explanation

When you close a parent dialog which has a nested dialog open, the nested dialog becomes invisible the next time you open the parent dialog, it prevents all input because only the nested dialog PART_ContentCoverGrid is visible:

with.transitions.mp4

This seems to work fine with TransitionAssist.DisableTransitions="True":

without.transitions.mp4

Steps:

  • Open Root dialog
  • Root dialog opens Inner dialog
  • Close Root dialog
  • Reopen Root dialog
    public RootDialog RootDialog { get; } = new();

    public MainWindow()
    {
        InitializeComponent();

        _ = Application.Current.Dispatcher.InvokeAsync(async () =>
        {
            await Delay();
            _ = DialogHost.Show(RootDialog);
            await Delay();
            RootDialog.OpenInnerDialog();
            await Delay();

            DialogHost.GetDialogSession(null)!.Close();

            await Delay();
            _ = DialogHost.Show(RootDialog);
        });

        static Task Delay() => Task.Delay(2000);
    }

I'm not sure if this is even desired behavior, I assumed that all nested dialogs would close when parent is closed.
Hope I described the issue clearly, its a little bit hard to explain.

Version

5.1.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugevaluation requiredItems is pending review or evaluation by the team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions