Skip to content

Commit cd1c22c

Browse files
committed
Update ContentDialogWindow.cs
1 parent ca52f76 commit cd1c22c

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

dev/DevWinUI.Controls/Controls/WindowedContentDialog/ContentDialogWindow.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ public partial class ContentDialogWindow : Window
1818
public ContentDialogWindow() : base()
1919
{
2020
ExtendsContentIntoTitleBar = true;
21-
_presenter = AppWindow.Presenter.As<OverlappedPresenter>();
22-
_presenter.IsMinimizable = false;
23-
_presenter.IsMaximizable = false;
21+
_presenter = OverlappedPresenter.CreateForDialog();
22+
_presenter.IsResizable = true;
23+
AppWindow.SetPresenter(_presenter);
2424

2525
AppWindow.Closing += (appWindow, e) => OnClosingRequestedBySystem();
2626
Activated += OnActivated;
@@ -30,7 +30,7 @@ public ContentDialogWindow() : base()
3030
_content.CloseButtonClick += OnCloseButtonClick;
3131
_content.PrimaryButtonClick += OnPrimaryButtonClick;
3232
_content.SecondaryButtonClick += OnSecondaryButtonClick;
33-
base.Content = _content;
33+
Content = _content;
3434

3535
// When showing accent color in title bar is enabled,
3636
// title bar buttons in the default custom title bar in WinUI3

0 commit comments

Comments
 (0)