Skip to content

Instantly share code, notes, and snippets.

@wsrzx
Created June 30, 2018 19:33
Show Gist options
  • Save wsrzx/c17cd42a6602ad4afb4368b59f242574 to your computer and use it in GitHub Desktop.
Save wsrzx/c17cd42a6602ad4afb4368b59f242574 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:behaviors="clr-namespace:AwesomeSeries.Behaviors;assembly=AwesomeSeries"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="AwesomeSeries.Views.MainView">
<ContentPage.Content>
<ListView
VerticalOptions="FillAndExpand"
HorizontalOptions="FillAndExpand"
HasUnevenRows="True"
SeparatorColor="DimGray"
CachingStrategy="RecycleElement"
ItemsSource="{Binding Items}"
behaviors:AttachedItemTappedBehavior.Command="{Binding ItemClickCommand}"
>
<ListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<StackLayout
Orientation="Horizontal"
VerticalOptions="FillAndExpand"
HorizontalOptions="FillAndExpand">
<Image Source="{Binding Poster}"
VerticalOptions="Start"
HorizontalOptions="Start"
HeightRequest="120" />
<StackLayout>
<Label Text="{Binding Name}" FontSize="Medium" />
<Label Text="{Binding OriginalName}" FontSize="Small" />
</StackLayout>
</StackLayout>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</ContentPage.Content>
</ContentPage>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment