-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMainWindow.xaml
140 lines (129 loc) · 9.47 KB
/
MainWindow.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
<Window x:Class="SavaMonitor.MainWindow"
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"
xmlns:local="clr-namespace:SavaMonitor"
xmlns:materialIcons="clr-namespace:Material.Icons.WPF;assembly=Material.Icons.WPF"
mc:Ignorable="d"
Title="Sava Monitor" Height="720" Width="1280" Background="#FFDFE3EE" Icon="/Resources/sava.ico" Closing="Window_Closing">
<Window.Resources>
<ControlTemplate x:Key="StatusBarButton" TargetType="Button">
<Grid>
<Rectangle Fill="{TemplateBinding Background}" Name="BackgroundElement"/>
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
<VisualStateManager.VisualStateGroups>
<VisualStateGroup Name="CommonStates">
<VisualState Name="Normal">
<Storyboard>
<ColorAnimation Storyboard.TargetName="BackgroundElement"
Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)"
To="{TemplateBinding Background}"
Duration="0:0:.1"/>
</Storyboard>
</VisualState>
<VisualState Name="MouseOver">
<Storyboard>
<ColorAnimation Storyboard.TargetName="BackgroundElement"
Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)"
To="#FF8F99AD"
Duration="0:0:.05"/>
</Storyboard>
</VisualState>
<VisualState Name="Pressed">
<Storyboard>
<ColorAnimation Storyboard.TargetName="BackgroundElement"
Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)"
To="#5c6373"
Duration="0:0:.05"/>
</Storyboard>
</VisualState>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
</Grid>
</ControlTemplate>
</Window.Resources>
<Grid>
<Grid Height="64px" VerticalAlignment="Top" Background="White" Margin="0, 0, 0, 0">
<StackPanel Orientation="Horizontal">
<Button x:Name="ShareScreenButton" HorizontalAlignment="Left" Width="96px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="ShareScreenButton_Click" Visibility="Visible">
<Grid>
<materialIcons:MaterialIcon Kind="Cast" Margin="4, 6, 4, 20"/>
<TextBlock Text="Share screen" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" />
</Grid>
</Button>
<Button x:Name="StopSharingScreenButton" HorizontalAlignment="Left" Width="96px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="StopSharingScreenButton_Click" Visibility="Collapsed">
<Grid>
<materialIcons:MaterialIcon Kind="CastOff" Margin="4, 6, 4, 20" Foreground="#FFDE2727"/>
<TextBlock Text="Stop sharing" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" Foreground="#FFDE2727" />
</Grid>
</Button>
<Separator Style="{StaticResource {x:Static ToolBar.SeparatorStyleKey}}"/>
<Button x:Name="SendMessageButton" HorizontalAlignment="Left" Width="106px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="SendMessageButton_Click">
<Grid>
<materialIcons:MaterialIcon Kind="MessageOutline" Margin="4, 6, 4, 20"/>
<TextBlock Text="Send message" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" />
</Grid>
</Button>
<Separator Style="{StaticResource {x:Static ToolBar.SeparatorStyleKey}}"/>
<Button x:Name="ShutdownButton" HorizontalAlignment="Left" Width="106px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="ShutdownButton_Click">
<Grid>
<materialIcons:MaterialIcon Kind="Shutdown" Margin="4, 6, 4, 20"/>
<TextBlock Text="Shut down" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" />
</Grid>
</Button>
<Separator Style="{StaticResource {x:Static ToolBar.SeparatorStyleKey}}"/>
<Button x:Name="AboutClassroomButton" HorizontalAlignment="Left" Width="106px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="AboutClassroomButton_Click">
<Grid>
<materialIcons:MaterialIcon Kind="Whiteboard" Margin="4, 6, 4, 20"/>
<TextBlock Text="About classroom" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" />
</Grid>
</Button>
<Separator Style="{StaticResource {x:Static ToolBar.SeparatorStyleKey}}"/>
<Button x:Name="AboutButton" HorizontalAlignment="Left" Width="106px" Height="64px" Background="Transparent" BorderBrush="{x:Null}" Click="AboutButton_Click">
<Grid>
<materialIcons:MaterialIcon Kind="AboutOutline" Margin="4, 6, 4, 20"/>
<TextBlock Text="About program" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="3,0,3,5" FontSize="12" FontWeight="Medium" TextWrapping="Wrap" TextAlignment="Center" />
</Grid>
</Button>
<Separator Style="{StaticResource {x:Static ToolBar.SeparatorStyleKey}}"/>
</StackPanel>
</Grid>
<Grid VerticalAlignment="Top" Height="12px" Margin="0, 64, 0 ,0" >
<Grid.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#3F000000" Offset="0.003"/>
<GradientStop Color="#00000000" Offset="1"/>
</LinearGradientBrush>
</Grid.Background>
</Grid>
<Frame x:Name="StudentViewFrame" Margin="0, 64, 0, 32" NavigationUIVisibility="Hidden"/>
<Grid VerticalAlignment="Bottom" Height="12px" Margin="0, 0, 0 ,32" >
<Grid.Background>
<LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
<GradientStop Color="#22000000" Offset="0"/>
<GradientStop Color="#00000000" Offset="1"/>
</LinearGradientBrush>
</Grid.Background>
</Grid>
<Grid Height="32px" VerticalAlignment="Bottom" Background="#FF7C8598" >
<StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
<Button x:Name="ListViewButton" Template="{StaticResource StatusBarButton}" Background="#5c6373" Width="48px" HorizontalAlignment="Left" BorderBrush="#5c6373" ToolTip="List view" Click="ListViewButton_Click">
<materialIcons:MaterialIcon Kind="ListBoxOutline" Margin="0, 2, 0, 2" Foreground="White"/>
</Button>
<Button x:Name="GridViewButton" Template="{StaticResource StatusBarButton}" Background="#848DA0" Width="48px" HorizontalAlignment="Left" BorderBrush="{x:Null}" ToolTip="Grid view" Click="GridViewButton_Click">
<materialIcons:MaterialIcon Kind="Grid" Margin="0, 4, 0, 4" Foreground="White"/>
</Button>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0, 0, 0, 0">
<Label x:Name="SelectedNumberLabel" Content="0 computers selected" Foreground="White" FontWeight="Regular" FontSize="14" VerticalAlignment="Center" Margin="8, 0, 8, 0"/>
<Button x:Name="SelectAllButton" Template="{StaticResource StatusBarButton}" Background="#FF848DA0" Width="96px" HorizontalAlignment="Left" BorderBrush="{x:Null}" ToolTip="Select all computers in the classroom" Click="SelectAllButton_Click">
<Label Content="Select all" Foreground="White" FontWeight="Medium" FontSize="14"/>
</Button>
<Button x:Name="AddStudentButton" Template="{StaticResource StatusBarButton}" Background="#FF848DA0" Width="48px" HorizontalAlignment="Left" BorderBrush="{x:Null}" ToolTip="Add a new computer to the classroom" Margin="8,0,0,0" Click="AddStudentButton_Click">
<materialIcons:MaterialIcon Kind="UserAdd" Margin="0, 4, 0, 4" Foreground="White"/>
</Button>
</StackPanel>
</Grid>
</Grid>
</Window>