summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs')
-rw-r--r--Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs24
1 files changed, 18 insertions, 6 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
index f40ece7e..0e762987 100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
@@ -566,8 +566,11 @@ namespace Xamarin.Forms.Platform.Tizen
return new ESize(NativeView.MinimumWidth, NativeView.MinimumHeight);
}
- protected virtual void UpdateBackgroundColor()
+ protected virtual void UpdateBackgroundColor(bool initialize)
{
+ if (initialize && Element.BackgroundColor.IsDefault)
+ return;
+
if (NativeView is Widget)
{
(NativeView as Widget).BackgroundColor = Element.BackgroundColor.ToNative();
@@ -578,8 +581,11 @@ namespace Xamarin.Forms.Platform.Tizen
}
}
- protected virtual void UpdateOpacity()
+ protected virtual void UpdateOpacity(bool initialize)
{
+ if (initialize && Element.Opacity == 1d)
+ return;
+
if (NativeView is Widget)
{
(NativeView as Widget).Opacity = (int)(Element.Opacity * 255.0);
@@ -764,8 +770,11 @@ namespace Xamarin.Forms.Platform.Tizen
/// <summary>
/// Updates the IsEnabled property.
/// </summary>
- void UpdateIsEnabled()
+ void UpdateIsEnabled(bool initialize)
{
+ if (initialize && Element.IsEnabled)
+ return;
+
var widget = NativeView as Widget;
if (widget != null)
{
@@ -776,8 +785,11 @@ namespace Xamarin.Forms.Platform.Tizen
/// <summary>
/// Updates the InputTransparent property.
/// </summary>
- void UpdateInputTransparent()
+ void UpdateInputTransparent(bool initialize)
{
+ if (initialize && Element.InputTransparent == default(bool))
+ return;
+
NativeView.PassEvents = Element.InputTransparent;
}
@@ -818,14 +830,14 @@ namespace Xamarin.Forms.Platform.Tizen
}
}
- void UpdateToolTip()
+ void UpdateToolTip(bool initialize)
{
var tooltip = Specific.GetToolTip(Element);
if (tooltip != null)
{
NativeView.SetTooltipText(tooltip);
}
- else
+ else if (!initialize)
{
NativeView.UnsetTooltip();
}