feat: layout calculation.

This commit is contained in:
rabbitism
2024-02-21 22:48:11 +08:00
parent ab4b74d055
commit 6f4e11c7f5
6 changed files with 166 additions and 34 deletions

View File

@@ -28,7 +28,6 @@ public class ToolBarItemTemplateSelector: IDataTemplate
{
[!ContentControl.ContentProperty] = new Binding() { Path = "Content" },
[!ToggleButton.IsCheckedProperty] = new Binding() { Path = "IsChecked" },
[!Button.CommandProperty] = new Binding() { Path = "Command" },
[!ToolBar.OverflowModeProperty] = new Binding(){ Path = "OverflowMode" }
};
}
@@ -39,7 +38,7 @@ public class ToolBarItemTemplateSelector: IDataTemplate
[!ContentControl.ContentProperty] = new Binding() { Path = "Content" },
[!SelectingItemsControl.SelectedItemProperty] = new Binding() { Path = "SelectedItem" },
[!ItemsControl.ItemsSourceProperty] = new Binding() { Path = "Items" },
[!ToolBar.OverflowModeProperty] = new Binding(){ Path = "OverflowMode" }
[ToolBar.OverflowModeProperty] = OverflowMode.Always,
};
}
return new Button() { Content = "Undefined Item" };