title: How access sender object of one button in click event of another button
body: <p>I am working on Xamarin.Forms and I have two buttons in my ListView and they are treated as radio button. On click event I am changing image property of button so that it works as a radio button. But in my case I need to have one button selected at one time. If user clicks on one radio button, other radio button should be automatically reset in order to only one button is selected at a time. 
  I am sharing code of ListView here-</p>
  
  <pre><code>&lt;ListView RowHeight="35"  SeparatorVisibility="None" BackgroundColor="{x:Static color:ColorResources.PageBackgroundColor}" HeightRequest="230" x:Name="listof_ingredients_and_lifestyleDiets"&gt;
                  &lt;ListView.ItemTemplate&gt;
                      &lt;DataTemplate&gt;
                          &lt;ViewCell&gt;
                             &lt;StackLayout Spacing="60" HorizontalOptions="FillAndExpand" Orientation="Horizontal"&gt;                           
                                  &lt;Label  Text="dipak" FontSize="14"  TextColor="{x:Static color:ColorResources.TextColor}" HorizontalOptions="CenterAndExpand" VerticalOptions="CenterAndExpand"/&gt; 
                                  &lt;Button Image="radio_Check.png" Clicked="OnAllergenTapped"   HeightRequest="25" WidthRequest="25" HorizontalOptions="CenterAndExpand" VerticalOptions="CenterAndExpand"/&gt;
                                  &lt;Button Image="radio_unCheck.png" Clicked="OnPreferenceTapped"   HeightRequest="25" WidthRequest="25" HorizontalOptions="CenterAndExpand" VerticalOptions="CenterAndExpand"/&gt;
                                  &lt;Button Image="deleteBtn.png" Clicked="btnDeleteClicked" HeightRequest="50" WidthRequest="40" HorizontalOptions="EndAndExpand" VerticalOptions="CenterAndExpand"/&gt;
                             &lt;/StackLayout&gt;
                         &lt;/ViewCell&gt;
                      &lt;/DataTemplate&gt;
                  &lt;/ListView.ItemTemplate&gt;
         &lt;/ListView&gt;
  </code></pre>
  
  <p>Also code behind for radio buttons click is here-</p>
  
  <pre><code>public void OnAllergenTapped(object sender, EventArgs e)
  {
      var s = sender as Button;
      if (flag_allergen == 1)
      {
          s.Image = "radio_uncheck.png";
          flag_allergen = 0;
          flag_preference = 1;
      }
      else
      {
          s.Image = "radio_Check.png";
          flag_allergen = 1;
          flag_preference = 0;
      }
  }
  public void OnPreferenceTapped(object sender, EventArgs e)
  {
      var s = sender as Button;
      if (flag_allergen == 1)
      {
          s.Image = "radio_uncheck.png";
          flag_allergen = 0;
          flag_preference = 1;
      }
      else
      {
          s.Image = "radio_Check.png";
          flag_allergen = 1;
          flag_preference = 0;
      }
  }    
  </code></pre>
  
  <p>The logic I used in above methods, not making any sense for me because it allows me to click both buttons simultaneously. What changes are required to make one button selected at a time?</p>