Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <UserControl x:Class="SpaceTakeover.LoginRegisterPage"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- mc:Ignorable="d" xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" d:DesignHeight="300" d:DesignWidth="400" Width="400" Height="300"
- Background="{StaticResource BackgroundBrush}">
- <Grid x:Name="LayoutRoot" Background="{StaticResource BackgroundBrush}">
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="77*" />
- <RowDefinition Height="223*" />
- </Grid.RowDefinitions>
- <Image Source="{Binding Source={StaticResource Banner}}" Grid.ColumnSpan="2" Grid.Row="0" Grid.Column="0" Stretch="UniformToFill" Name="bannerMainPage" />
- <!-- Begin Define Login Form-->
- <Grid Name="LoginForm" Margin="10" Grid.Row="1" Grid.Column="0" Background="DarkSlateBlue">
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- </Grid.RowDefinitions>
- <TextBlock Name="LoginErrorText" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.ColumnSpan="2" Foreground="Red" FontWeight="Bold" />
- <Border Grid.Row="0" Grid.RowSpan="4" Grid.Column="0" Grid.ColumnSpan="2" BorderBrush="Black" BorderThickness="3" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />
- <TextBlock Grid.Row="1" Grid.Column="0" Text="Username:" Style="{StaticResource TextStyle}" />
- <TextBox Grid.Column="1" Name="UsernameLogin" Style="{StaticResource TextBoxRegStyle}" MaxLength="15" Text="{Binding Path=LoginInfo.Username, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" Grid.Row="1" />
- <TextBlock Grid.Row="2" Grid.Column="0" Text="Password:" VerticalAlignment="Center" HorizontalAlignment="Left" Style="{StaticResource TextStyle}" />
- <PasswordBox Grid.Row="2" Grid.Column="1" Name="Password" Style="{StaticResource PasswordBoxRegStyle}" Password="{Binding Path=LoginInfo.Password, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" />
- <Button Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="3" VerticalAlignment="Center" HorizontalAlignment="Center" Name="LoginButton" Command="{Binding Path=LoginCmd}" CommandParameter="{Binding ElementName=LoginErrorText}" Content="Login" />
- </Grid>
- <!-- End Define Login Form-->
- <!-- Begin Define Registration Form-->
- <Grid Name="RegistrationForm" Margin="10" Grid.Row="1" Grid.Column="1" Background="DarkSlateBlue">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*" />
- <ColumnDefinition Width="*" />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- <RowDefinition Height="*" />
- </Grid.RowDefinitions>
- <Border Grid.Row="0" Grid.RowSpan="7" Grid.Column="0" Grid.ColumnSpan="2" BorderBrush="Black" BorderThickness="3" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />
- <TextBlock Name="RegistrationErrorText" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.ColumnSpan="2" Foreground="Red" FontWeight="Bold" />
- <TextBlock Text="Username:" Style="{StaticResource TextStyle}" Grid.Column="0" Grid.Row="1" />
- <TextBox Name="UsernameRegister" Grid.Column="1" Style="{StaticResource TextBoxRegStyle}" MaxLength="15" Text="{Binding Path=RegistrationData.Username, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" Grid.Row="1" />
- <TextBlock Text="Password:" Style="{StaticResource TextStyle}" Grid.Column="0" Grid.Row="2" />
- <PasswordBox Name="PasswordRegister" Style="{StaticResource PasswordBoxRegStyle}" Grid.Column="1" Grid.Row="2" Password="{Binding Path=RegistrationData.Password, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" />
- <TextBlock Text="Re-Enter:" Style="{StaticResource TextStyle}" Grid.Column="0" Grid.Row="3" />
- <PasswordBox Name="ReEnterPassword" Style="{StaticResource PasswordBoxRegStyle}" Grid.Column="1" Grid.Row="3" Password="{Binding Path=RegistrationData.ReEnterPassword, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" />
- <TextBlock Style="{StaticResource TextStyle}" Text="Beta Key:" Grid.Column="0" Grid.Row="4" />
- <PasswordBox Style="{StaticResource PasswordBoxRegStyle}" Grid.Column="1" Grid.Row="4" Name="BetaKey" Password="{Binding Path=RegistrationData.BetaKey, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" />
- <TextBlock Style="{StaticResource TextStyle}" Text="Email:" Grid.Column="0" Grid.Row="5" />
- <TextBox Name="Email" Style="{StaticResource TextBoxRegStyle}" Grid.Column="1" Grid.Row="5" Text="{Binding Path=RegistrationData.Email, Mode=TwoWay, ValidatesOnDataErrors=True,ValidatesOnExceptions=True, ValidatesOnNotifyDataErrors=True, NotifyOnValidationError=True}" />
- <Button Name="RegisterButton" Grid.ColumnSpan="2" Grid.Row="6" VerticalAlignment="Center" HorizontalAlignment="Center" IsEnabled="{Binding Path=RegistrationData.RegisterEnabled, Mode=OneWay}" Command="{Binding Path=RegisterCmd}" CommandParameter="{Binding ElementName=RegistrationErrorText}" Content="Register" />
- </Grid>
- <!--End Define Registration Form-->
- </Grid>
- </UserControl>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement