summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Android
diff options
context:
space:
mode:
authorJason Smith <jason.smith@xamarin.com>2016-10-14 10:21:52 (GMT)
committerRui Marinho <me@ruimarinho.net>2016-10-14 10:21:52 (GMT)
commit28378d6354d55e86896287a60c0973515c48d64d (patch)
treeb5a2dc010771c3357877d2c60e1bcdfe0726ab24 /Xamarin.Forms.Platform.Android
parentd16f3550dcacb92b36e8c7ec5d4547cd97d001bf (diff)
downloadxamarin-forms-28378d6354d55e86896287a60c0973515c48d64d.zip
xamarin-forms-28378d6354d55e86896287a60c0973515c48d64d.tar.gz
xamarin-forms-28378d6354d55e86896287a60c0973515c48d64d.tar.bz2
[A] Better fix for BZ44129 (#453)
Diffstat (limited to 'Xamarin.Forms.Platform.Android')
-rw-r--r--Xamarin.Forms.Platform.Android/AppCompat/TabbedPageRenderer.cs6
1 files changed, 4 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.Android/AppCompat/TabbedPageRenderer.cs b/Xamarin.Forms.Platform.Android/AppCompat/TabbedPageRenderer.cs
index 5149909..5400252 100644
--- a/Xamarin.Forms.Platform.Android/AppCompat/TabbedPageRenderer.cs
+++ b/Xamarin.Forms.Platform.Android/AppCompat/TabbedPageRenderer.cs
@@ -253,9 +253,13 @@ namespace Xamarin.Forms.Platform.Android.AppCompat
((FormsFragmentPagerAdapter<Page>)pager.Adapter).CountOverride = Element.Children.Count;
+ pager.Adapter.NotifyDataSetChanged();
if (Element.Children.Count == 0)
+ {
tabs.RemoveAllTabs();
+ tabs.SetupWithViewPager(null);
+ }
else
{
tabs.SetupWithViewPager(pager);
@@ -263,8 +267,6 @@ namespace Xamarin.Forms.Platform.Android.AppCompat
tabs.SetOnTabSelectedListener(this);
}
- pager.Adapter.NotifyDataSetChanged();
-
UpdateIgnoreContainerAreas();
}