App layout
This commit is contained in:
@@ -4,27 +4,86 @@
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:viewModels="clr-namespace:DotNetSolutionTools.App.ViewModels"
|
||||
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
|
||||
Width="800" Height="450"
|
||||
x:Class="DotNetSolutionTools.App.Views.MainWindow"
|
||||
x:DataType="viewModels:MainWindowViewModel"
|
||||
Icon="/Assets/avalonia-logo.ico"
|
||||
Title="FileOps">
|
||||
Title="DotNetSolutionTools">
|
||||
<Design.DataContext>
|
||||
<!-- This only sets the DataContext for the previewer in an IDE,
|
||||
to set the actual DataContext for runtime, set the DataContext property in code (look at App.axaml.cs) -->
|
||||
<viewModels:MainWindowViewModel />
|
||||
</Design.DataContext>
|
||||
<Panel>
|
||||
<StackPanel>
|
||||
<TextBlock>Welcome to Avalonia!</TextBlock>
|
||||
<Button Command="{Binding LoadSolutionFolderCommand}" >Select Solution Folder</Button>
|
||||
<Button Command="{Binding LoadSolutionFileCommand}">Select Solution File</Button>
|
||||
<Button Command="{Binding ExecuteParityCheckerCommand}">Check Solution Parity</Button>
|
||||
<Button Command="{Binding FormatCsProjFileCommand}">Format CSharp Project File</Button>
|
||||
<TextBlock Name="SolutionFilePath" Text="{Binding SolutionFilePath}" />
|
||||
<TextBlock Name="SolutionFolderPath" Text="{Binding SolutionFolderPath}" />
|
||||
<ListBox Name="Results" ItemsSource="{Binding ParityResults}"/>
|
||||
<ListBox ItemsSource="{Binding ErrorMessages}"/>
|
||||
<StackPanel VerticalAlignment="Stretch" Margin="10">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Button Width="200" HorizontalContentAlignment="Center" Command="{Binding LoadSolutionFolderCommand}">Select Solution Folder</Button>
|
||||
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Background="Gray" Name="SolutionFolderPath" Text="{Binding SolutionFolderPath}" />
|
||||
<Button Width="60" HorizontalContentAlignment="Center" Command="{Binding ClearSolutionFolderCommand}">Clear</Button>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Button Width="200" HorizontalContentAlignment="Center" Command="{Binding LoadSolutionFileCommand}">Select Solution File</Button>
|
||||
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Name="SolutionFilePath" Text="{Binding SolutionFilePath}" />
|
||||
<Button Width="60" HorizontalContentAlignment="Center" Command="{Binding ClearSolutionFileCommand}">Clear</Button>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Button Width="200" HorizontalContentAlignment="Center" Command="{Binding LoadCsprojFileCommand}">Select CSharp Project File</Button>
|
||||
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Background="Gray" Name="CsprojFilePath" Text="{Binding CsprojFilePath}" />
|
||||
<Button Width="60" HorizontalContentAlignment="Center" Command="{Binding ClearCsprojFileCommand}">Clear</Button>
|
||||
|
||||
</StackPanel>
|
||||
<Separator Margin="0 10 0 0" />
|
||||
<Grid VerticalAlignment="Stretch" ShowGridLines="False" RowDefinitions="*,*" ColumnDefinitions="*,*,*">
|
||||
<Button Grid.Row="0" Grid.Column="0" MinHeight="130" Padding="10" Margin="10"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
VerticalContentAlignment="Center" HorizontalContentAlignment="Center"
|
||||
IsEnabled="{Binding SolutionFolderPath, Mode=OneWay, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"
|
||||
Command="{Binding ExecuteParityCheckerCommand}">
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Check Solution Parity
|
||||
</TextBlock>
|
||||
</Button>
|
||||
<Button Grid.Row="0" Grid.Column="1" MinHeight="130" Padding="10" Margin="10"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
VerticalContentAlignment="Center" HorizontalContentAlignment="Center"
|
||||
IsEnabled="{Binding CsprojFilePath, Mode=OneWay, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"
|
||||
Command="{Binding FormatCsProjFileCommand}">
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Format CSharp Project File
|
||||
</TextBlock>
|
||||
</Button>
|
||||
<Button Grid.Row="0" Grid.Column="2" MinHeight="130" Padding="10" Margin="10"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
VerticalContentAlignment="Center" HorizontalContentAlignment="Center"
|
||||
IsEnabled="{Binding SolutionFilePath, Mode=OneWay, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"
|
||||
Command="{Binding FormatAllCsprojFilesInSolutionFileCommand}">
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Format All CSharp Project Files in Solution
|
||||
</TextBlock>
|
||||
</Button>
|
||||
<Button Grid.Row="1" Grid.Column="0" MinHeight="130" Padding="10" Margin="10"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
VerticalContentAlignment="Center" HorizontalContentAlignment="Center"
|
||||
IsEnabled="{Binding SolutionFolderPath, Mode=OneWay, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"
|
||||
Command="{Binding FormatAllCsprojFilesInSolutionFolderCommand}">
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Format All CSharp Project Files in Folder
|
||||
</TextBlock>
|
||||
|
||||
</Button>
|
||||
<Button Grid.Row="1" Grid.Column="1" MinHeight="130" Padding="10" Margin="10"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
VerticalContentAlignment="Center" HorizontalContentAlignment="Center"
|
||||
IsEnabled="{Binding SolutionFilePath, Mode=OneWay, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"
|
||||
Command="{Binding CheckForMissingImplicitUsingsInSolutionFileCommand}">
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Check For Missing Implicit Usings
|
||||
</TextBlock>
|
||||
</Button>
|
||||
</Grid>
|
||||
<ListBox Name="Results" ItemsSource="{Binding ParityResults}" />
|
||||
<ListBox ItemsSource="{Binding ErrorMessages}" />
|
||||
</StackPanel>
|
||||
</Panel>
|
||||
|
||||
|
||||
</Window>
|
||||
Reference in New Issue
Block a user