source: other-projects/playing-in-the-street/summer-2013/trunk/Playing-in-the-Street-WPF/MainWindow.xaml@ 28897

Last change on this file since 28897 was 28897, checked in by davidb, 7 years ago

GUI front-end to server base plus web page content

File size: 3.2 KB
Line 
1<Window x:Class="Microsoft.Samples.Kinect.WebserverBasics.MainWindow"
2 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
3 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
4 xmlns:tk="clr-namespace:Microsoft.Kinect.Toolkit;assembly=Microsoft.Kinect.Toolkit"
5 xmlns:local="clr-namespace:Microsoft.Samples.Kinect.WebserverBasics"
6 Title="Webserver Basics" SizeToContent="Height" Width="800" FontSize="16"
7 Loaded="WindowLoaded" Closing="WindowClosing">
8
9 <Window.Resources>
10 <local:InverseBooleanConverter x:Key="inverseBooleanConverter"/>
11 </Window.Resources>
12
13 <Grid>
14 <Grid.ColumnDefinitions>
15 <ColumnDefinition Width="Auto"/>
16 <ColumnDefinition Width="Auto"/>
17 <ColumnDefinition Width="*"/>
18 </Grid.ColumnDefinitions>
19 <Grid.RowDefinitions>
20 <RowDefinition Height="Auto"/>
21 <RowDefinition Height="*"/>
22 </Grid.RowDefinitions>
23 <tk:KinectSensorChooserUI Grid.Row="0" Grid.Column="0" KinectSensorChooser="{Binding KinectSensorChooser}" HorizontalAlignment="Left" IsListening="False" Margin="5"/>
24 <DockPanel Grid.Row="0" Grid.Column="1" Margin="5">
25 <Button DockPanel.Dock="Top" Height="50" Width="100" Content="Start"
26 IsEnabled="{Binding Path=IsStarted, Converter={StaticResource inverseBooleanConverter}}" Click="StartButtonOnClick"/>
27 <Button DockPanel.Dock="Top" Height="50" Width="100" Content="Stop"
28 IsEnabled="{Binding Path=IsStarted}" Click="StopButtonOnClick"/>
29 </DockPanel>
30 <StackPanel Grid.Row="0" Grid.Column="2" Margin="10 0">
31 <TextBlock x:Name="OpenBrowserText" Margin="0 5">
32 <Hyperlink FontSize="16" x:Name="UriLink" Click="UriLinkOnClick">Open sample page in default browser</Hyperlink>
33 <LineBreak/>
34 <Run FontSize="11">See documentation for list of supported browsers</Run>
35 </TextBlock>
36 <TextBlock x:Name="ServingFilesText" Margin="0 5" FontSize="11" TextWrapping="WrapWithOverflow">
37 <Run FontSize="14" FontWeight="Bold">Serving files from:</Run>
38 <Run x:Name="RootDirectoryTextRun"/>
39 <LineBreak/>
40 Edit FileRootDirectory property in configuration file (.exe.config) and restart server application to serve files from a different directory.
41 </TextBlock>
42 <TextBlock x:Name="NotServingFilesText" Margin="0 5" FontSize="14" FontWeight="Bold" Visibility="Collapsed">
43 Not Serving Files
44 </TextBlock>
45 </StackPanel>
46 <Expander Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="3" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5 0 5 5"
47 ExpandDirection="Down" IsExpanded="True"
48 Header="Errors:" FontWeight="Black">
49 <TextBox IsReadOnly="True" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Auto" MinHeight="200"
50 FontSize="10" Text="{Binding Path=ErrorText}"/>
51 </Expander>
52 </Grid>
53</Window>
Note: See TracBrowser for help on using the repository browser.