I have a requirement of making tabs for main categories for browsing.
The requirement
Functionality Gif
What I want is that there should be a fixed indicator(two arrows from top and bottom)always at the center of the tablayout indicating the currently selected tab.At the same time only the tabs should have singluar scroll functionality(Similar to how we select the card expiry date i.e. ring like scroll).So what will happen is the indicator will be fixed and user will scroll the tab, lets say one at a time and that will come in center and for that the fragment will load below. I am not sure how to go about it as I am new to Android and I am developing in Xamarin Android.
Currently my Main Layout looks like this.You can rectify If I am doing something wrong.
<Relative Layout>
<LinearLayout>
--For toolbar and search View --
<AppBarLayout>
<include toolbar>
<SearchView>
</AppBarLayout>
<DrawerLayout>
<CoordinatorLayout>
<AppBarLayout>
<CustomTabLayout>
//Customized tablayout which makes currently selected tabs in center by adjusting padding.
</CustomTabLayout>
</AppBarLayout>
<NonSwipeableViewPager>
</NonSwipeableViewPager>
</CoordinatorLayout>
</DrawerLayout>
--For Navigation Drawer and TabLayout and ViewPager
</LinearLayout>
</Relative Layout>
So from the code I dont want the viewpagers swipe functionality(which I have achieved) since the swipe will be for tabs above like a ring remember(I just asked).ANd the tabslayout are in center since I adjusted the tabs padding to be at center always. I need a concrete solution to my problem please help me out I can change the layout if need be. If question is not clear please comment I can explain again, its quire unique requirement.