summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.iOS/ResourcesProvider.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Xamarin.Forms.Platform.iOS/ResourcesProvider.cs')
-rw-r--r--Xamarin.Forms.Platform.iOS/ResourcesProvider.cs22
1 files changed, 6 insertions, 16 deletions
diff --git a/Xamarin.Forms.Platform.iOS/ResourcesProvider.cs b/Xamarin.Forms.Platform.iOS/ResourcesProvider.cs
index cb5e3cf..3e5655c 100644
--- a/Xamarin.Forms.Platform.iOS/ResourcesProvider.cs
+++ b/Xamarin.Forms.Platform.iOS/ResourcesProvider.cs
@@ -8,8 +8,7 @@ namespace Xamarin.Forms.Platform.iOS
public ResourcesProvider()
{
- if (Forms.IsiOS7OrNewer)
- UIApplication.Notifications.ObserveContentSizeCategoryChanged((sender, args) => UpdateStyles());
+ UIApplication.Notifications.ObserveContentSizeCategoryChanged((sender, args) => UpdateStyles());
}
public IResourceDictionary GetSystemResources()
@@ -45,20 +44,11 @@ namespace Xamarin.Forms.Platform.iOS
void UpdateStyles()
{
- if (Forms.IsiOS7OrNewer)
- {
- _dictionary[Device.Styles.TitleStyleKey] = GenerateStyle(UIFont.PreferredHeadline);
- _dictionary[Device.Styles.SubtitleStyleKey] = GenerateStyle(UIFont.PreferredSubheadline);
- _dictionary[Device.Styles.BodyStyleKey] = GenerateStyle(UIFont.PreferredBody);
- _dictionary[Device.Styles.CaptionStyleKey] = GenerateStyle(UIFont.PreferredCaption1);
- }
- else
- {
- _dictionary[Device.Styles.TitleStyleKey] = GenerateStyle(UIFont.BoldSystemFontOfSize(17));
- _dictionary[Device.Styles.SubtitleStyleKey] = GenerateStyle(UIFont.SystemFontOfSize(15));
- _dictionary[Device.Styles.BodyStyleKey] = GenerateStyle(UIFont.SystemFontOfSize(17));
- _dictionary[Device.Styles.CaptionStyleKey] = GenerateStyle(UIFont.SystemFontOfSize(12));
- }
+
+ _dictionary[Device.Styles.TitleStyleKey] = GenerateStyle(UIFont.PreferredHeadline);
+ _dictionary[Device.Styles.SubtitleStyleKey] = GenerateStyle(UIFont.PreferredSubheadline);
+ _dictionary[Device.Styles.BodyStyleKey] = GenerateStyle(UIFont.PreferredBody);
+ _dictionary[Device.Styles.CaptionStyleKey] = GenerateStyle(UIFont.PreferredCaption1);
_dictionary[Device.Styles.ListItemTextStyleKey] = GenerateListItemTextStyle();
_dictionary[Device.Styles.ListItemDetailTextStyleKey] = GenerateListItemDetailTextStyle();