diff --git a/Bloxstrap/Resources/CustomBootstrapperSchema.json b/Bloxstrap/Resources/CustomBootstrapperSchema.json index 5bd2b58..f29ff75 100644 --- a/Bloxstrap/Resources/CustomBootstrapperSchema.json +++ b/Bloxstrap/Resources/CustomBootstrapperSchema.json @@ -30,7 +30,8 @@ "SuperClass": "Control", "IsCreatable": true, "Attributes": { - "Theme": "Theme" + "Theme": "Theme", + "Title": "string" } }, "TitleBar": { diff --git a/Bloxstrap/UI/Elements/Bootstrapper/CustomDialog.Creator.cs b/Bloxstrap/UI/Elements/Bootstrapper/CustomDialog.Creator.cs index d47e109..f472c3c 100644 --- a/Bloxstrap/UI/Elements/Bootstrapper/CustomDialog.Creator.cs +++ b/Bloxstrap/UI/Elements/Bootstrapper/CustomDialog.Creator.cs @@ -501,6 +501,9 @@ namespace Bloxstrap.UI.Elements.Bootstrapper dialog.Margin = new Thickness(0, 0, 0, 0); dialog.Padding = new Thickness(0, 0, 0, 0); + string? title = xmlElement.Attribute("Title")?.Value?.ToString() ?? "Bloxstrap"; + dialog.Title = title; + return new DummyFrameworkElement(); } @@ -528,7 +531,6 @@ namespace Bloxstrap.UI.Elements.Bootstrapper dialog.RootTitleBar.ShowClose = ParseXmlAttribute(xmlElement, "ShowClose", true); string? title = xmlElement.Attribute("Title")?.Value?.ToString() ?? "Bloxstrap"; - dialog.Title = title; dialog.RootTitleBar.Title = title; return new DummyFrameworkElement(); // dont add anything