[WPF, GTK, TIZEN] Replace obsolete OutlineColor by BorderColor (#1443)
This commit is contained in:
Родитель
5ea86a266b
Коммит
66b6f9f482
|
@ -35,7 +35,7 @@ namespace Xamarin.Forms.Platform.GTK.Renderers
|
|||
PackChild();
|
||||
}
|
||||
if (e.PropertyName == VisualElement.BackgroundColorProperty.PropertyName ||
|
||||
e.PropertyName == Frame.OutlineColorProperty.PropertyName ||
|
||||
e.PropertyName == Frame.BorderColorProperty.PropertyName ||
|
||||
e.PropertyName == Frame.HasShadowProperty.PropertyName)
|
||||
SetupLayer();
|
||||
}
|
||||
|
@ -47,10 +47,10 @@ namespace Xamarin.Forms.Platform.GTK.Renderers
|
|||
else
|
||||
Control.SetBackgroundColor(Element.BackgroundColor.ToGtkColor());
|
||||
|
||||
if (Element.OutlineColor == Color.Default)
|
||||
if (Element.BorderColor == Color.Default)
|
||||
Control.ResetBorderColor();
|
||||
else
|
||||
Control.SetBorderColor(Element.OutlineColor.ToGtkColor());
|
||||
Control.SetBorderColor(Element.BorderColor.ToGtkColor());
|
||||
|
||||
if (Element.HasShadow)
|
||||
Control.SetShadow();
|
||||
|
|
|
@ -17,7 +17,7 @@ namespace Xamarin.Forms.Platform.Tizen
|
|||
|
||||
public FrameRenderer()
|
||||
{
|
||||
RegisterPropertyHandler(Frame.OutlineColorProperty, UpdateColor);
|
||||
RegisterPropertyHandler(Frame.BorderColorProperty, UpdateColor);
|
||||
RegisterPropertyHandler(Frame.HasShadowProperty, UpdateShadowVisibility);
|
||||
}
|
||||
|
||||
|
@ -105,10 +105,10 @@ namespace Xamarin.Forms.Platform.Tizen
|
|||
|
||||
void UpdateColor()
|
||||
{
|
||||
if (Element.OutlineColor.IsDefault)
|
||||
if (Element.BorderColor.IsDefault)
|
||||
_frame.Color = s_DefaultColor;
|
||||
else
|
||||
_frame.Color = Element.OutlineColor.ToNative();
|
||||
_frame.Color = Element.BorderColor.ToNative();
|
||||
}
|
||||
|
||||
void UpdateShadowVisibility()
|
||||
|
|
|
@ -37,7 +37,7 @@ namespace Xamarin.Forms.Platform.WPF
|
|||
|
||||
if (e.PropertyName == Frame.ContentProperty.PropertyName)
|
||||
UpdateContent();
|
||||
else if (e.PropertyName == Frame.OutlineColorProperty.PropertyName || e.PropertyName == Frame.HasShadowProperty.PropertyName)
|
||||
else if (e.PropertyName == Frame.BorderColorProperty.PropertyName || e.PropertyName == Frame.HasShadowProperty.PropertyName)
|
||||
UpdateBorder();
|
||||
else if (e.PropertyName == Frame.CornerRadiusProperty.PropertyName)
|
||||
UpdateCornerRadius();
|
||||
|
@ -61,9 +61,9 @@ namespace Xamarin.Forms.Platform.WPF
|
|||
|
||||
void UpdateBorder()
|
||||
{
|
||||
if (Element.OutlineColor != Color.Default)
|
||||
if (Element.BorderColor != Color.Default)
|
||||
{
|
||||
Control.UpdateDependencyColor(Border.BorderBrushProperty, Element.OutlineColor);
|
||||
Control.UpdateDependencyColor(Border.BorderBrushProperty, Element.BorderColor);
|
||||
Control.BorderThickness = new System.Windows.Thickness(1);
|
||||
}
|
||||
else
|
||||
|
|
Загрузка…
Ссылка в новой задаче