diff options
Diffstat (limited to 'Xamarin.Forms.Core/TabbedPage.cs')
-rw-r--r-- | Xamarin.Forms.Core/TabbedPage.cs | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/Xamarin.Forms.Core/TabbedPage.cs b/Xamarin.Forms.Core/TabbedPage.cs index 5fb6bf9c..ee9b81ff 100644 --- a/Xamarin.Forms.Core/TabbedPage.cs +++ b/Xamarin.Forms.Core/TabbedPage.cs @@ -1,14 +1,17 @@ +using System; using Xamarin.Forms.Platform; namespace Xamarin.Forms { [RenderWith(typeof(_TabbedPageRenderer))] - public class TabbedPage : MultiPage<Page> + public class TabbedPage : MultiPage<Page>, IElementConfiguration<TabbedPage> { public static readonly BindableProperty BarBackgroundColorProperty = BindableProperty.Create(nameof(BarBackgroundColor), typeof(Color), typeof(TabbedPage), Color.Default); public static readonly BindableProperty BarTextColorProperty = BindableProperty.Create(nameof(BarTextColor), typeof(Color), typeof(TabbedPage), Color.Default); + readonly Lazy<PlatformConfigurationRegistry<TabbedPage>> _platformConfigurationRegistry; + public Color BarBackgroundColor { get @@ -41,5 +44,15 @@ namespace Xamarin.Forms return page; } + + public TabbedPage() + { + _platformConfigurationRegistry = new Lazy<PlatformConfigurationRegistry<TabbedPage>>(() => new PlatformConfigurationRegistry<TabbedPage>(this)); + } + + public new IPlatformElementConfiguration<T, TabbedPage> On<T>() where T : IConfigPlatform + { + return _platformConfigurationRegistry.Value.On<T>(); + } } }
\ No newline at end of file |