Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/xamarin/Xamarin.PropertyEditing.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLarry Ewing <lewing@xamarin.com>2018-05-18 21:40:17 +0300
committerLarry Ewing <lewing@microsoft.com>2018-07-16 22:05:49 +0300
commitd483b8506f858f3927ec39225cbe63a7de158ff8 (patch)
tree590ca8d75de8bfb654fbc897442ee7fc54cf6eb2 /Xamarin.PropertyEditing.Mac/Controls/Custom
parent7e23b42f670e9436981c5eea6aca557f8e922510 (diff)
Make initialization a little more consistent
Diffstat (limited to 'Xamarin.PropertyEditing.Mac/Controls/Custom')
-rw-r--r--Xamarin.PropertyEditing.Mac/Controls/Custom/ColorComponentEditor.cs11
1 files changed, 6 insertions, 5 deletions
diff --git a/Xamarin.PropertyEditing.Mac/Controls/Custom/ColorComponentEditor.cs b/Xamarin.PropertyEditing.Mac/Controls/Custom/ColorComponentEditor.cs
index 25a3516..0a17a23 100644
--- a/Xamarin.PropertyEditing.Mac/Controls/Custom/ColorComponentEditor.cs
+++ b/Xamarin.PropertyEditing.Mac/Controls/Custom/ColorComponentEditor.cs
@@ -48,9 +48,13 @@ namespace Xamarin.PropertyEditing.Mac
var ce = new ChannelGroup {
Label = new UnfocusableTextField {
StringValue = $"{editor.Name}:",
- Alignment = NSTextAlignment.Right
+ Alignment = NSTextAlignment.Right,
+ BackgroundColor = NSColor.Clear
+ },
+ Editor = new ComponentSpinEditor (editor) {
+ BackgroundColor = NSColor.Clear,
+ TranslatesAutoresizingMaskIntoConstraints = true
},
- Editor = new ComponentSpinEditor (editor),
Gradient = new UnanimatedGradientLayer {
StartPoint = new CGPoint (0, 0),
EndPoint = new CGPoint (1, 0),
@@ -58,10 +62,7 @@ namespace Xamarin.PropertyEditing.Mac
}
};
- ce.Editor.TranslatesAutoresizingMaskIntoConstraints = true;
ce.Editor.ValueChanged += UpdateComponent;
- ce.Editor.BackgroundColor = NSColor.Clear;
- ce.Label.BackgroundColor = NSColor.Clear;
AddSubview (ce.Label);
AddSubview (ce.Editor);