public void SetInitialTab(string title, int index) { OnTabSelected?.Invoke(title); ImageView tab = (ImageView)layout.GetChildAt(index); tab.SetImageResource(SelectedIcons[index]); }
private void Tab_Selected(object sender, EventArgs e, int i) { for (int index = 0; index < layout.ChildCount; index++) { ImageView tab = (ImageView)layout.GetChildAt(index); tab.SetImageResource(DefaultIcons[index]); } ImageView view = sender as ImageView; view.SetImageResource(SelectedIcons[i]); switch (i) { case 0: OnTabSelected?.Invoke("Home"); break; case 1: OnTabSelected?.Invoke("Explore"); break; case 2: OnTabSelected?.Invoke("Notifications"); break; case 3: OnTabSelected?.Invoke("Profile"); break; } }
public void Select(ShopSection section) { OnTabSelected?.Invoke(section); }