<?xml version="1.0" encoding="utf-8"?>
<Window
    x:Class="HelloXaml.MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:HelloXaml"
    xmlns:Models="using:HelloXaml.Models"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Grid Background="LightGray">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="auto"/>
            <ColumnDefinition Width="*"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="60"/>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="60"/>
        </Grid.RowDefinitions>

        <TextBlock Text="Lorem" Grid.Row="0" Grid.Column="0" VerticalAlignment="Center" HorizontalAlignment="Center"/>
        <TextBlock Text="Ipsum" Grid.Row="1" Grid.Column="0" VerticalAlignment="Center" HorizontalAlignment="Center"/>

        <Button Margin="4,4,4,4" Click="Btn1Click" Content="Pariatur" Grid.Row="0" Grid.Column="1" Width="100" Height="30" VerticalAlignment="Center" HorizontalAlignment="Center"/>
        <TextBox x:Name="t1" Text="{x:Bind data, Mode=TwoWay}" Margin="4,4,4,4" Grid.Row="1" Grid.Column="1" HorizontalAlignment="Left" Width="200"/>
        <TextBox x:Name="t2" Margin="4,4,4,4" Grid.Row="2" Grid.Column="1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />

    </Grid>
    
    <!--3. feladat-->
    <ListView ItemsSource="{x:Bind dataList}" SelectedItem="{x:Bind selectedItem, Mode=TwoWay}">
        <ListView.ItemTemplate>
            <DataTemplate>
                <StackPanel Margin="0,3">
                    <CheckBox Content="In Basket" IsChecked="{x:Bind IsInBasket, Mode=TwoWay}"></CheckBox>
                    <TextBlock Text="{x:Bind Name}"></TextBlock>
                </StackPanel>
            </DataTemplate>
        </ListView.ItemTemplate>

    </ListView>

    <!--<ListView ItemsSource="{x:Bind People}" SelectedItem="{x:Bind selectedItem, Mode=TwoWay}" Margin="0,0,0,0">
        <ListView.ItemTemplate>
            <DataTemplate x:DataType="Models:person">
                <Grid Margin="0" >
                    <TextBlock Text="{x:Bind name}"></TextBlock>
                    <TextBox Text="{x:Bind name, Mode=TwoWay}" Margin="0,20,0,0"></TextBox>
                    <CheckBox IsChecked="{x:Bind smthVal}" Content="SmthVal" Margin="0,40,0,0"></CheckBox>
                </Grid>
            </DataTemplate>
        </ListView.ItemTemplate>
    </ListView>-->

</Window>
