optimized performance
This commit is contained in:
1 parent
c407997a3c
commit
3162267795
65 files changed
+168
-168
No files matched your search
+2
-1
@@ -5,6 +5,7 @@ using System.Windows.Controls.Primitives;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Shapes;
|
||||
using HandyControl.Data;
|
||||
using HandyControl.Tools;
|
||||
|
||||
namespace HandyControl.Controls
|
||||
@@ -35,7 +36,7 @@ namespace HandyControl.Controls
|
||||
|
||||
var factory = new FrameworkElementFactory(typeof(Path));
|
||||
factory.SetValue(FrameworkElement.WidthProperty, 12.0);
|
||||
factory.SetValue(FrameworkElement.HeightProperty, 10.0);
|
||||
factory.SetValue(FrameworkElement.HeightProperty, ValueBoxes.Double10Box);
|
||||
factory.SetBinding(Shape.FillProperty, new Binding(Control.ForegroundProperty.Name)
|
||||
{
|
||||
RelativeSource = new RelativeSource
|
||||
|
||||
+2
-1
@@ -5,6 +5,7 @@ using System.Windows.Controls.Primitives;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Shapes;
|
||||
using HandyControl.Data;
|
||||
using HandyControl.Tools;
|
||||
|
||||
namespace HandyControl.Controls
|
||||
@@ -34,7 +35,7 @@ namespace HandyControl.Controls
|
||||
};
|
||||
|
||||
var factory = new FrameworkElementFactory(typeof(Path));
|
||||
factory.SetValue(FrameworkElement.WidthProperty, 10.0);
|
||||
factory.SetValue(FrameworkElement.WidthProperty, ValueBoxes.Double10Box);
|
||||
factory.SetValue(FrameworkElement.HeightProperty, 12.0);
|
||||
factory.SetBinding(Shape.FillProperty, new Binding(Control.ForegroundProperty.Name)
|
||||
{
|
||||
|
||||
@@ -68,7 +68,7 @@ namespace HandyControl.Controls
|
||||
public bool IsReadOnly
|
||||
{
|
||||
get => (bool)GetValue(IsReadOnlyProperty);
|
||||
set => SetValue(IsReadOnlyProperty, value);
|
||||
set => SetValue(IsReadOnlyProperty, ValueBoxes.BooleanBox(value));
|
||||
}
|
||||
|
||||
public static readonly DependencyProperty DefaultValueProperty = DependencyProperty.Register(
|
||||
@@ -113,7 +113,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 IsExpandedEnabledProperty = DependencyProperty.Register(
|
||||
@@ -122,7 +122,7 @@ namespace HandyControl.Controls
|
||||
public bool IsExpandedEnabled
|
||||
{
|
||||
get => (bool)GetValue(IsExpandedEnabledProperty);
|
||||
set => SetValue(IsExpandedEnabledProperty, value);
|
||||
set => SetValue(IsExpandedEnabledProperty, ValueBoxes.BooleanBox(value));
|
||||
}
|
||||
|
||||
public PropertyDescriptor PropertyDescriptor { get; set; }
|
||||
|
||||
Reference in new issue
Block a user