-
Notifications
You must be signed in to change notification settings - Fork 2
/
MainWindow.xaml
59 lines (55 loc) · 2.77 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
<!--
Copyright © 2017 László Csöndes
This file is part of Secret Splitter.
Secret Splitter is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Secret Splitter is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with Secret Splitter. If not, see <http://www.gnu.org/licenses/>.
-->
<Window x:Class="SecretSplit.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:SecretSplit"
mc:Ignorable="d"
Title="Secret Splitter" Height="350" Width="525">
<Window.Resources>
<Style TargetType="TextBox">
<Setter Property="Margin" Value="4,4,4,4"/>
</Style>
<Style TargetType="Button">
<Setter Property="Margin" Value="4,4,4,4"/>
</Style>
</Window.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Grid.Row="0">Secret:</Label>
<TextBox Name="textSecret" Grid.Column="1" Grid.Row="0" Grid.ColumnSpan="2"/>
<StackPanel Grid.Column="0" Grid.Row="1" Orientation="Horizontal">
<TextBox Name="textNeededCount" Width="24" PreviewTextInput="ValidateNumbersOnly">2</TextBox>
<Label>of</Label>
<TextBox Name="textTotalCount" Width="24" PreviewTextInput="ValidateNumbersOnly">2</TextBox>
</StackPanel>
<Button Grid.Column="1" Grid.Row="1" Click="SplitSecret_Click">↓ Split secret ↓</Button>
<Button Grid.Column="2" Grid.Row="1" Click="MergeSecret_Click"
MouseEnter="Button_MouseEnter" MouseLeave="Button_MouseLeave">↑ Merge secret ↑</Button>
<Label Grid.Column="0" Grid.Row="2">Parts:</Label>
<TextBox Name="textParts" Grid.Column="1" Grid.Row="2" Grid.ColumnSpan="2" TextWrapping="Wrap" AcceptsReturn="True"/>
</Grid>
</Window>