diff --git a/Ooui.Forms/VisualElementTracker.cs b/Ooui.Forms/VisualElementTracker.cs index 18a5cc9..ab65c78 100644 --- a/Ooui.Forms/VisualElementTracker.cs +++ b/Ooui.Forms/VisualElementTracker.cs @@ -149,7 +149,12 @@ namespace Ooui.Forms else if (width <= 0 || height <= 0) { return; } - uiview.Style.Opacity = opacity; + if (opacity >= 1.0f) { + uiview.Style.Opacity = null; + } + else { + uiview.Style.Opacity = opacity; + } //var transform = 0; //const double epsilon = 0.001; diff --git a/Ooui/Style.cs b/Ooui/Style.cs index 0a8cb08..a92f6d3 100644 --- a/Ooui/Style.cs +++ b/Ooui/Style.cs @@ -338,7 +338,8 @@ namespace Ooui var safeValue = value ?? "inherit"; lock (properties) { if (value == null) { - properties.Remove (propertyName); + if (!properties.Remove (propertyName)) + return; } else { Value old;