MainPage.xaml 4.02 KB
Newer Older
1 2 3 4 5 6
<Page
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:Linphone"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
7 8
    xmlns:Model="using:Linphone.Model"
    x:Class="Linphone.MainPage"
9
    mc:Ignorable="d">
10 11 12
    <Page.DataContext>
        <Model:LinphoneManager/>
    </Page.DataContext>
13 14

    <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
        <StackPanel x:Name="stackPanel" Margin="8">
            <TextBlock x:Name="RegistrationTitle" TextWrapping="Wrap" Style="{StaticResource HeaderTextBlockStyle}" VerticalAlignment="Center" Text="Register" Margin="0,8"/>
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="Auto"/>
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition/>
                </Grid.ColumnDefinitions>
                <TextBlock x:Name="UsernameTextBlock" HorizontalAlignment="Left" Margin="8,0" TextWrapping="Wrap" VerticalAlignment="Center" Text="Username:"/>
                <TextBox x:Name="UsernameTextBox" Margin="8" TextWrapping="Wrap" VerticalAlignment="Center" d:LayoutOverrides="Width" Grid.Column="1"/>
                <TextBlock x:Name="PasswordTextBlock" Margin="8,0" Grid.Row="1" TextWrapping="Wrap" Text="Password:" VerticalAlignment="Center" d:LayoutOverrides="Width"/>
                <PasswordBox x:Name="PasswordBox" Margin="8" d:LayoutOverrides="Width, Height" Grid.Row="1" Grid.Column="1" HorizontalContentAlignment="Stretch"/>
                <TextBlock x:Name="ServerTextBlock" HorizontalAlignment="Left" Margin="8,0" TextWrapping="Wrap" VerticalAlignment="Center" Grid.Row="2" Text="Server:"/>
                <TextBox x:Name="ServerTextBox" Margin="8" TextWrapping="Wrap" VerticalAlignment="Center" d:LayoutOverrides="Width" Grid.Row="2" Grid.Column="1" Text="sip.linphone.org"/>
                <Button x:Name="RegisterButton" Content="Register" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="8,0" Grid.Row="3" d:LayoutOverrides="Height, TopPosition, BottomPosition" Click="RegisterButton_Click"/>
                <TextBlock x:Name="RegistrationStateTextBlock" Margin="8" TextWrapping="Wrap" Grid.Row="3" Grid.Column="1" Text="{Binding Instance.RegistrationStateText}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
            </Grid>
            <TextBlock x:Name="CallTitle" TextWrapping="Wrap" Style="{StaticResource HeaderTextBlockStyle}" VerticalAlignment="Center" Text="Call" Margin="0,8"/>
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="Auto"/>
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition/>
                </Grid.ColumnDefinitions>
                <TextBlock x:Name="ContactTextBlock" HorizontalAlignment="Left" Margin="8,0" TextWrapping="Wrap" VerticalAlignment="Center" Text="Contact:"/>
                <TextBox x:Name="ContactTextBox" Margin="8" TextWrapping="Wrap" VerticalAlignment="Center" d:LayoutOverrides="Width" Grid.Column="1"/>
Ghislain MARY's avatar
Ghislain MARY committed
49
                <Button x:Name="CallButton" Content="Call / Hangup" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="8,0" Grid.Row="1" d:LayoutOverrides="Height, TopPosition, BottomPosition" Click="CallButton_Click"/>
50 51 52
                <TextBlock x:Name="CallStateTextBlock" Margin="8,8,5,8" TextWrapping="Wrap" Grid.Row="1" Grid.Column="1" Text="{Binding Instance.CallStateText}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
            </Grid>
        </StackPanel>
53 54 55

    </Grid>
</Page>