optimized performance

This commit is contained in:
NaBian committed 2020-06-28 22:39:27 +08:00
1 parent c407997a3c
commit 3162267795
65 files changed
+168 -168

No files matched your search

@@ -67,7 +67,7 @@ namespace HandyControl.Controls
public bool IsSelected
{
get => (bool)GetValue(IsSelectedProperty);
set => SetValue(IsSelectedProperty, value);
set => SetValue(IsSelectedProperty, ValueBoxes.BooleanBox(value));
}
public static readonly DependencyProperty SelfManageProperty = DependencyProperty.Register(
@@ -76,7 +76,7 @@ namespace HandyControl.Controls
public bool SelfManage
{
get => (bool) GetValue(SelfManageProperty);
set => SetValue(SelfManageProperty, value);
set => SetValue(SelfManageProperty, ValueBoxes.BooleanBox(value));
}
public static readonly DependencyProperty CanDeselectProperty = DependencyProperty.Register(
@@ -85,7 +85,7 @@ namespace HandyControl.Controls
public bool CanDeselect
{
get => (bool) GetValue(CanDeselectProperty);
set => SetValue(CanDeselectProperty, value);
set => SetValue(CanDeselectProperty, ValueBoxes.BooleanBox(value));
}
public static readonly RoutedEvent SelectedEvent =
@@ -38,7 +38,7 @@ namespace HandyControl.Controls
{
if (e.NewItems != null && e.NewItems.Count > 0)
{
SetValue(HasItemsPropertyKey, true);
SetValue(HasItemsPropertyKey, ValueBoxes.TrueBox);
}
OnItemsChanged(s, e);
};