summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.ControlGallery.iOS
diff options
context:
space:
mode:
authorSamantha Houts <samantha@teamredwall.com>2016-06-28 03:25:45 -0700
committerRui Marinho <me@ruimarinho.net>2016-06-28 11:25:45 +0100
commit0772a5278b96f289ff216f10da86b072bc6edbf1 (patch)
treedbf54e33abc93749d230b6ba6996abcd653f5d89 /Xamarin.Forms.ControlGallery.iOS
parent589adbd3ef145ec85f9fe64eda008251c1cdb745 (diff)
downloadxamarin-forms-0772a5278b96f289ff216f10da86b072bc6edbf1.tar.gz
xamarin-forms-0772a5278b96f289ff216f10da86b072bc6edbf1.tar.bz2
xamarin-forms-0772a5278b96f289ff216f10da86b072bc6edbf1.zip
[iOS] Default BarTextColor/BarBackgroundColor will no longer override values set in custom renderers (#233)beta-2.3.1-pre1
* [Controls] Improve TabbedPage test case iOS should default to the color used in a custom renderer instead of to the global default color. * [iOS] TabbedPage Bar*Color default is better Will use the color set by a custom renderer, if any, instead of always pulling from global appearance.
Diffstat (limited to 'Xamarin.Forms.ControlGallery.iOS')
-rw-r--r--Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs13
1 files changed, 12 insertions, 1 deletions
diff --git a/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs b/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs
index 44d86644..92b58455 100644
--- a/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs
+++ b/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs
@@ -28,7 +28,7 @@ using MonoTouch.CoreLocation;
[assembly: ExportRenderer(typeof(NativeListView2), typeof(NativeiOSListViewRenderer))]
[assembly: ExportRenderer(typeof(NativeListView), typeof(NativeListViewRenderer))]
[assembly: ExportRenderer(typeof(CustomMapView), typeof(CustomIOSMapRenderer))]
-
+[assembly: ExportRenderer(typeof(TabbedPage), typeof(TabbedPageWithCustomBarColorRenderer))]
namespace Xamarin.Forms.ControlGallery.iOS
{
public class CustomIOSMapRenderer : ViewRenderer<CustomMapView, MKMapView>
@@ -593,5 +593,16 @@ namespace Xamarin.Forms.ControlGallery.iOS
}
}
+ public class TabbedPageWithCustomBarColorRenderer : TabbedRenderer
+ {
+ public TabbedPageWithCustomBarColorRenderer()
+ {
+ TabBar.TintColor = UIColor.White;
+ TabBar.BarTintColor = UIColor.Purple;
+
+ //UITabBar.Appearance.TintColor = UIColor.White;
+ //UITabBar.Appearance.BarTintColor = UIColor.Purple;
+ }
+ }
}