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:
authorDominique Louis <dominique@DIPRAJ1.northamerica.corp.microsoft.com>2019-04-29 13:06:38 +0300
committerDominique Louis <dominique@DIPRAJ1.northamerica.corp.microsoft.com>2019-05-01 16:43:57 +0300
commit24f6af3d4526ba0c474fb4ea1664676a47bf7794 (patch)
treea7f9a53745172cd0fb56eff7985fb0e198c776b5 /Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs
parent40c2ea08e7c2796b73e464bda91353551a477e27 (diff)
[Mac] Move appearance setting calls outside ViewDidChangeEffectiveApperance, so it works on earlier MacOS versions.
Diffstat (limited to 'Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs')
-rw-r--r--Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs22
1 files changed, 11 insertions, 11 deletions
diff --git a/Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs b/Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs
index d5e038c..005ef89 100644
--- a/Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs
+++ b/Xamarin.PropertyEditing.Mac/Controls/BaseRectangleEditorControl.cs
@@ -114,17 +114,7 @@ namespace Xamarin.PropertyEditing.Mac
NSLayoutConstraint.Create (HeightLabel, NSLayoutAttribute.CenterX, NSLayoutRelation.Equal, HeightEditor.Subviews[0], NSLayoutAttribute.CenterX, 1f, 0),
});
- ViewDidChangeEffectiveAppearance ();
- }
-
- public override void ViewDidChangeEffectiveAppearance ()
- {
- XLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
- YLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
- WidthLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
- HeightLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
-
- base.ViewDidChangeEffectiveAppearance ();
+ AppearanceChanged ();
}
protected virtual void OnInputUpdated (object sender, EventArgs e)
@@ -154,5 +144,15 @@ namespace Xamarin.PropertyEditing.Mac
HeightEditor.AccessibilityEnabled = HeightEditor.Enabled;
HeightEditor.AccessibilityTitle = string.Format (Properties.Resources.AccessibilityHeightEditor, ViewModel.Property.Name);
}
+
+ protected override void AppearanceChanged ()
+ {
+ base.AppearanceChanged ();
+
+ XLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
+ YLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
+ WidthLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
+ HeightLabel.TextColor = HostResources.GetNamedColor (NamedResources.DescriptionLabelColor);
+ }
}
}